Commit graph

91 commits

Author SHA1 Message Date
Jonathan Kelley
d3be971f4e chore: rollback to option instead of anyhow 2022-12-19 18:06:13 -08:00
Evan Almloff
c74a16b8d4 remove references to renderer features 2022-12-19 12:10:50 -06:00
Jonathan Kelley
0bf4725639 fix: namespacing of dynamic attributes 2022-12-07 15:11:51 -08:00
Jonathan Kelley
a252774226 chore: clean up docs with changes to templates 2022-12-07 13:39:22 -08:00
Jonathan Kelley
4eefc3f854 chore: rename all &cx to cx, make clipppy happy 2022-12-07 13:11:40 -08:00
Jonathan Kelley
c1c5821dcf Merge branch 'master' into jk/templates-v3 2022-11-16 22:12:16 -08:00
Jonathan Kelley
0dad91bc08 wip: pass more events 2022-11-15 16:37:23 -08:00
Miles Murgaw
0085b9cb1d
Fix the Android support disagreement in the docs (#614) 2022-11-10 12:41:25 -08:00
Demonthos
047ed1e553
Subtree memorization / reactive templates (#488)
This commit adds subtree memoization to Dioxus.

Subtree memoization is basically a compile-time step that drastically 
reduces the amount of work the diffing engine needs to do at runtime by
extracting non-changing nodes out into a static "template." Templates 
are then understood by the various renderers in the ecosystem as a 
faster way of rendering the same items. 

For example, in the web, templates are simply a set of DOM Nodes created 
once and then cloned later. This is the same pattern frameworks like Lithtml
and SolidJS use to achieve near-perfect performance. 

Subtree memoization adds an additional level of complexity to Dioxus. The RSX
macro needs to be much smarter to identify changing/nonchanging nodes and
generate a mapping between the Template and its runtime counterparts.

This commit represents a working starter point for this work, adding support 
for templates for the web, desktop, liveview, ssr, and native-core renderers.
In the future we will try to shrink code generation, generally improve 
performance, and simplify our implementation.
2022-09-30 12:03:06 -07:00
Jon Kelley
28fba42e7e
feat: add an unhygenic render macro (#556)
* feat: add an unhygenic render macro

* chore: use render instead of rsx!(cx,
2022-09-25 01:05:16 -07:00
Jon Kelley
540e785d8b
Less clumsy configuration for desktop and mobile (#553)
* chore: dont use prebuilt builder pattern for configuring desktop

* chore: use regular config pattern for web

* Chore: update docs too

* chore: clean up some warnings
2022-09-13 16:22:27 -07:00
Altug Sahin
0c421f6e8c
Document formatting and typo fixes (#495)
* minor formatting

* Internationalization: move guide to en folder and preserve its history. (#494)

* chore: move guide to en folder

* docs: add english as language

* merged conf resolved

* chore: remove outdated docs

* chore: use taffy dimension directly

* Add PT-BR translations (#456)

* Translate final.md, hello_world.md, README.md, ROADMAP.md and SUMMARY.md

* Translatation complete

* Internationalization: move guide to en folder and preserve its history. (#494)

* Clean files and build mdBook with localization feature

* Rebase, remove leftovers and check book builds for every language: 

Co-authored-by: Jon Kelley <jkelleyrtp@gmail.com>

* Remove argument from `use_hook` closure (#496)

Also; update docs for said function

* chore: prevent reference from being uploaded

Co-authored-by: Altug Sahin <altugsahin@gmail.com>
Co-authored-by: Jon Kelley <jkelleyrtp@gmail.com>
Co-authored-by: Breno Rocha <66398400+amindWalker@users.noreply.github.com>
Co-authored-by: Reinis Mazeiks <rMazeiks@users.noreply.github.com>
Co-authored-by: = <evanalmloff@gmail.com>
2022-09-05 13:58:19 -05:00
Reinis Mazeiks
c801d4402e
Fix propagation docs (#526)
* Fix typo - wrong example for "stopping propagation" section

* Move `lib.rs` in guide back to `src`

* Make sure tests get run when guide is updated (there's examples in the guide to check for compilation errors)
2022-08-10 07:23:27 -05:00
Marco Godoy
9538cfe733
Update Docs CI with mdbook translation support (#516)
* Update Docs CI with mdbook translation support #514

* install mdbook with --rev
2022-08-04 10:26:04 -05:00
Marc Espín
df5338f4e6
Fix typos and update code (#513) 2022-07-30 07:20:49 -05:00
Breno Rocha
6ea076fa7f
Add PT-BR translations (#456)
* Translate final.md, hello_world.md, README.md, ROADMAP.md and SUMMARY.md

* Translatation complete

* Internationalization: move guide to en folder and preserve its history. (#494)

* Clean files and build mdBook with localization feature

* Rebase, remove leftovers and check book builds for every language: 

Co-authored-by: Jon Kelley <jkelleyrtp@gmail.com>
2022-07-11 13:28:12 -04:00
Jonathan Kelley
2369b0cc7f chore: remove outdated docs 2022-07-09 15:22:54 -04:00
Jon Kelley
d9546d9504
Renderers are now packages, not features. (#387)
* feat: use synchronous router design

* feat: function to get router out of dom

* chore: restructure workspace to use renderers as packages, not features
2022-07-09 15:15:20 -04:00
Jon Kelley
c97ca7dff6
Internationalization: move guide to en folder and preserve its history. (#494)
* chore: move guide to en folder

* docs: add english as language
2022-07-09 12:31:46 -04:00
Reinis Mazeiks
6c323e9fc5
Rework Guide (#486)
* Move getting started to Guide

* Clean up summary and getting started

* Shorten intro by moving stuff to individual platform docs

* Make intro even shorter, summarize features

* Further cleanup; move development-related docs to separate section

* Make `guide` a crate. Turn code samples into examples so that we can check if they compile

* Rewrite "Describing the UI":

* Focus on RSX syntax (interactivity covered in later chapters); make sure samples are tested; concise language

* Move some "special attribute" samples to the `examples` directory

* Simplify introduction to components

* Simplify introduction to component props

* Document Prop features; add code samples

* Simplify component children docs

* Interactivity: better introduction to events

* Hooks: better introduction

* Remove outdated doc

* Introducs use_ref

* Simplify User Input chapter

* Document event handler props

* Meme editor example

* Meme editor walkthrough

* Add dark mode example

* Guide for context; dark mode example

* Guide: custom hooks

* Guide: conditional rendering

* Guide: rendering lists

* Guide: rendering lists + keys

* Move remaining infor from Reference to guide

* Delete reference book
2022-07-07 08:50:36 +00:00
Reinis Mazeiks
0ab2f38314 Guide: remove empty and almost empty pages
(Avoids confusion and improves navigation)
2022-06-30 22:39:34 +03:00
Reinis Mazeiks
f3fcec2bdf Merge branch 'master' of https://github.com/DioxusLabs/dioxus into rusty-events
 Conflicts:
	packages/html/src/events.rs
	packages/tui/src/hooks.rs
2022-06-28 21:09:20 +03:00
xTeKc
af951f30ce
update dead link 2022-06-12 04:10:42 -04:00
xTeKc
287cef96b1
fix link 2022-06-12 04:02:21 -04:00
Alejandro Osornio
6520b24d67
Update index.md
+ Fix outdated documentation
2022-06-01 15:52:43 -05:00
Reinis Mazeiks
45980f9a1e Update examples to avoid deprecated API 2022-05-12 15:00:43 +03:00
Jonathan Moore
21df7d2142
Fix typo 2022-05-05 17:49:08 -05:00
YuKun Liu
c9537a4c41
Update localstate.md 2022-04-17 12:27:41 +08:00
Jon Kelley
d8a6d61723
Merge pull request #335 from kdwarn/master 2022-04-02 14:50:37 -04:00
YuKun Liu
8e1e06d8c3
fix: docs 2022-03-28 13:11:33 +08:00
Kris Warner
e61fa44497 Make minor grammar, spelling, and style changes 2022-03-27 21:24:14 -04:00
Kris Warner
cb1e16c91c Fix name of later chapter 2022-03-26 10:58:54 -04:00
Kris Warner
36ccb835ab Clarify that expr in string literal limit of Rust 2022-03-26 10:52:55 -04:00
Kris Warner
55b818b08d Fix link to router guide 2022-03-26 00:04:58 -04:00
Kris Warner
2ffd90c98b Remove bullets from numbered list 2022-03-25 22:36:40 -04:00
Kris Warner
e57c0890ec Delete redundant sentence 2022-03-25 22:26:42 -04:00
Jon Kelley
d3ac3db296
Merge pull request #315 from Synphonyte/master
Option<...> props are optional by default.
2022-03-20 19:59:35 -04:00
Imbolc
1082472756
Update setup.md
A typo
2022-03-20 08:42:45 +03:00
Marc-Stefan Cassola
be55524e69
Change optional props docs 2022-03-15 19:49:16 +00:00
Jonathan Kelley
38d07f7111 docs: add some more to async 2022-03-09 12:33:28 -05:00
Jonathan Kelley
3e9023b131 docs: finish async 2022-03-09 10:22:12 -05:00
Jonathan Kelley
be2b4d36de fix: linking in attributions 2022-03-08 14:43:19 -05:00
Jonathan Kelley
c6fdd03a9d feat: add attributions for crates 2022-03-08 14:41:49 -05:00
Jonathan Kelley
3acd643afb docs: more docs and an errorhandling example 2022-03-08 14:15:18 -05:00
Jonathan Kelley
59f38839fa
Merge pull request #295 from DioxusLabs/jk/docsoverhaul
Docs: actually finish all of the documentation.
2022-03-08 00:56:44 -05:00
Jonathan Kelley
0f87ebb277 docs: even more docs 2022-03-06 20:37:57 -05:00
YuKun Liu
485f6f69f0
Update hooks.md 2022-03-06 15:05:21 +08:00
Jörg Kurlbaum
cc0e2c4877 Add options for compilation on systems that lack libappindicator3 2022-02-24 14:32:43 +01:00
Oliver Forral
d700850b70
fixing build warnings in hello world example
Fixing this warning when I try to compile

warning: function `App` should have a snake case name
 --> src/main.rs:7:4
  |
7 | fn App(cx: Scope) -> Element {
  |    ^^^ help: convert the identifier to snake case: `app`
  |
  = note: `#[warn(non_snake_case)]` on by default

Also changing edition from 2018 to 2021
2022-02-20 17:27:07 -07:00
Miles Murgaw
2fea2fb13a Merge branch 'master' of https://github.com/DioxusLabs/dioxus 2022-02-15 13:39:02 -05:00