Commit Graph
16 Commits
Author SHA1 Message Date
Jon Kelley 8ea61e1b3e feat: simple iterators and conditionals in rsx (#564)
* feat: simple iterators

* fix: into_iter

* feat: add support for unterminated conditionasl

* fix: add tempalte mapping for helpers
2022-11-16 22:10:50 -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 38e8745db9 Remove lower case components that use the paran syntax (#551)
* chore: remove lowercase components

* chore: add docs are lowercase components

* docs: also add docs around lowercase components in current scope
2022-09-12 20:01:03 -07:00
Jonathan Kelley 30c1e702b3 fix: fmt 2022-07-02 22:49:19 -04:00
Jonathan Kelley a825cdcf58 feat: simple support for comments 2022-06-28 15:01:51 -04:00
Evan Almloff ffc9bf763a pass clippy 2022-06-17 13:50:41 -05:00
Evan Almloff 9e7e5b0859 Merge remote-tracking branch 'upstream/master' into jk/rsx-refactor 2022-06-16 09:17:36 -05:00
Evan Almloff 94448ea4aa handle formatting options 2022-05-30 18:32:57 -05:00
Evan Almloff 06390b9be5 allow rsx to be used outside of a proc_macro context 2022-05-28 12:10:32 -05:00
Evan Almloff a0c7e4d78a add component support 2022-05-27 09:47:44 -05:00
Jonathan Kelley 804d9af1c7 feat: improve autoformatting algorithm
- tons of new tests for various cases to be consistent
2022-04-26 18:45:08 -04:00
Jonathan Kelley 2a1970b3a9 feat: add prettyplease vendored and get basic test working 2022-04-24 02:55:20 -04:00
Jonathan Kelley 794f43ffee concept: move rsx out to its own crate 2022-04-24 02:35:52 -04:00
Ilya Maximov b8573bc4dd refactor: remove the rsx folder
it doesn't seem to be published anywhere or used at all
2022-03-19 20:35:53 +01:00
Jonathan Kelley 237f036a80 wip: add meta to rsx 2022-02-18 23:26:47 -05:00
Jonathan Kelley b93487282d feat: move files around 2022-02-18 20:54:30 -05:00