tivac / xstate-component-tree Goto Github PK
View Code? Open in Web Editor NEWBuild a tree of UI components based on your statechart
License: MIT License
Build a tree of UI components based on your statechart
License: MIT License
Used here in the codebase:
xstate-component-tree/src/component-tree.js
Line 300 in e83845c
Removal is here:
Will need to become data.state.children
, it sounds like?
Need to not re-run load
or prop
functions if it's a state that existed in the previous run. Means each instance of ComponentTree needs to track the previous values for each possible state ID and then not re-run them if they're found in the cache.
Hello!
In doing some interesting edge-casery, the meta
tag in the component helper is actually stomping on meta
data that might already exist on a statenode, the offending line is essentially right here
you can see that there's a raw assignment to node.meta = meta
, which causes anything that might previously already exist on that statenode's metadata to be lost.
This is just an issue that was in the back of my mind that I might put a CR up for, but essentially it's as simple as us running an Object.assign
for the existing meta with the new metadata that is the loading component..
I'm unsure if we want this to be compatible with other load
calls in the statenode meta (if people need to do other asynchronous work), but if we do, we should also augment the load function to include the already existing node.meta.load
if there is one.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.