Commit Graph
60 Commits
Author SHA1 Message Date
Evan Almloff 0127501dbf Improve inline docs (#2460)
Improve inline docs

* improve incorrect event handler return error message

* Improve event handler docs

* document the eval functions

* document spawn and common spawn errors

* fix event handler docs

* add notes about how you use attributes and elements in rsx

* add doc aliases for attributes and events we rename

* add some more aliases for common search terms

* don't doc ignore any public examples in core

* don't ignore public doc examples in ssr

* don't ignore examples in the dioxus package readme

* add a warning when you launch without a renderer enabled

* fix some outdated element docs

* add a bunch of examples to resource

* add notes about desktop events

* add more docs for use_resource

* add on_unimplemented hint to Dependency

* fix some unresolved links

* add examples to each of the router traits

* add not implemented errors for router traits

* add an example to the routable trait

* expand rsx macro docs

* improve memo docs

* update the dioxus readme

* mention dioxus crate features in the docs

* fix a bunch of doc tests

* fix html doc tests

* fix router doc tests

* fix dioxus signals doc tests

* fix dioxus ssr doc tests

* fix use_future example in the hooks cheat sheet

* add a javascript alias for eval

* fix hook explanation values

* remove unused embed-doc-image dependency
2024-06-06 18:15:17 -07:00
Evan Almloff 5290b658fd Fix effects triggered from async tasks; improve work scheduling docs (#2370)
* outline work scheduling

* move scheduling code from dirty_scope to scheduler

* introduce queue_effect

* Run effects after all tasks are polled if there are no components rerendered

* add a new test for async effects
2024-05-04 15:30:13 +01:00
Evan Almloff 5ce91e1bfc Fix flakey windows tests (#2332) 2024-04-17 15:08:38 -07:00
Marc Espin 29f69fa145 fix: Update use_hook docs (#2296)
* fix: Update `use_hook` docs

* rust

* fixes
2024-04-11 15:43:58 -05:00
Evan Almloff 5df333fca2 fix and test spawn_forever (#2216) 2024-04-02 10:52:00 -07:00
Evan Almloff bbc81b8f9c fix memos in children; introduce isomorphic spawn 2024-03-08 16:40:31 -06:00
Evan Almloff c9603ea984 only poll suspended futures 2024-03-05 18:24:01 -06:00
Evan Almloff 48751d2f98 only subscribe scopes to signals when rendering 2024-02-14 09:33:22 -06:00
Jonathan Kelley 7c2947a131 Implement effects using reactivecontext 2024-02-01 13:21:52 -08:00
Jonathan Kelley dcdada542b Properly implement wait_for_suspense
Wait_for_suspense now does not call flush_sync, making it
appropriate for deferring effects on the server. Futures will
still run on the server (as needed to progress suspense)
but use_effect / and memo watchers will not run on the server
2024-01-29 14:12:05 -08:00
Jonathan Kelley 1847c737e9 Queue effects to run after flush_sync 2024-01-28 02:21:05 -08:00
Jonathan Kelley 7b0dcb3206 Add flush_sync and pre_render methods to core 2024-01-28 01:30:33 -08:00
Evan Almloff 458c13fb74 run effects in the scope they were created in 2024-01-24 18:34:22 -06:00
Evan Almloff cdf25f0c14 run hook destructors inside of the scope they were created in 2024-01-22 09:32:53 -06:00
Evan Almloff 8f786d85cd drop hooks before contexts 2024-01-22 09:08:29 -06:00
Evan Almloff bc914deeaa create Signal::global 2024-01-19 13:46:17 -06:00
Jonathan Kelley 127709f83f Tiny aesthetic tweaks 2024-01-18 10:59:43 -08:00
Jonathan Kelley 3008870818 Cleanup runtime code 2024-01-16 17:38:39 -08:00
Jonathan Kelley 8b9bf57c03 Cleanup core more 2024-01-16 17:23:34 -08:00
Evan Almloff e65c5f0eb3 depreciate the render macro 2024-01-16 13:18:46 -06:00
Evan Almloff 7e4d2debe0 implement launch builder for the desktop and web platforms 2024-01-16 08:42:16 -06:00
Jonathan Kelley a32ae8b112 Remove push_future, get use_future kinda working again 2024-01-15 19:34:04 -08:00
Jonathan Kelley ee5020c41f actually set task 2024-01-15 17:37:50 -08:00
Jonathan Kelley 1332b82dc8 Expose current task 2024-01-15 17:32:49 -08:00
Evan Almloff af1749d7be re export renderers in dioxus 2024-01-15 19:14:11 -06:00
Evan Almloff 16d5d00bdf fix ssr tests 2024-01-15 11:12:24 -06:00
Evan Almloff 20480c0a2d fix use_hook imports 2024-01-15 09:10:15 -06:00
Jonathan Kelley fae0b08e61 Fix the router and stub out a number of crates to get compiling 2024-01-13 20:51:37 -08:00
Jonathan Kelley 8c94f0bc4a get compiling 2024-01-11 16:51:18 -08:00
Jonathan Kelley 2ae3241cc0 Merge branch 'master' into jk/breaking-merged 2024-01-11 16:04:36 -08:00
Evan Almloff 6c29e2b825 clean up some core context APIs 2024-01-11 17:21:13 -06:00
Evan Almloff 3267ddec10 more consistent naming of the root component in core 2024-01-11 15:23:37 -06:00
Evan Almloff fd0a53ab63 make all core tests compile 2024-01-11 15:18:11 -06:00
Jonathan Kelley b8061d6d14 Make clippy happy 2024-01-10 23:26:26 -08:00
Evan Almloff 3545c14a38 fix formatting 2024-01-09 11:36:45 -06:00
Jonathan Kelley 8323e45970 Call handlers from context of a runtime and scope 2024-01-05 17:35:37 -08:00
Evan Almloff 4013341b6c hello world example working 2024-01-05 18:01:05 -06:00
Evan Almloff 3865f44081 make desktop compile 2024-01-05 14:39:45 -06:00
Evan Almloff d90c71c508 move creation functions into the structs they are creating and unify user and system events 2024-01-05 13:18:48 -06:00
Evan Almloff a4a9aa5224 create a global once function 2024-01-05 12:31:20 -06:00
Evan Almloff 32b15fc851 make core compile 2024-01-05 12:25:18 -06:00
Evan Almloff c70e2bfcb6 move diffing into the global runtime 2024-01-05 09:32:50 -06:00
Evan Almloff 3ad16ddd37 rip out more lifetimes 2024-01-04 18:33:01 -06:00
Jonathan Kelley ea1325f6e8 Merge branch 'master' into polish-throw 2024-01-04 10:27:51 -08:00
ealmloff 2e424436b3 don't remove futures spawned by spawn_forever when the component is removed (#1708) 2024-01-03 14:02:36 -06:00
Evan Almloff 6141aeb037 polish the throw trait 2023-11-07 18:24:07 -06:00
Evan Almloff 248d78fbfe fix clippy 2023-10-05 15:45:34 -05:00
Evan Almloff bc3b781136 fix runtime import 2023-09-10 13:25:19 -05:00
Evan Almloff 66333e9767 improve context tracing 2023-09-08 10:00:05 -05:00
Jani MustonenandJani Mustonen 31f8bab20d Add ScopeId::ROOT (#1398)
* add ScopeId::ROOT

* replace ScopeId(0) with ScopeId::ROOT

---------

Co-authored-by: Jani Mustonen <jani.mustonen@taitounited.fi>
2023-08-25 08:31:23 -05:00