alloy / relational-theory Goto Github PK
View Code? Open in Web Editor NEWA prototype of server-side React+Relay rendering.
A prototype of server-side React+Relay rendering.
From #19
For bigger projects I'd encourage a modular architecture. E.g. what we do in Force/MG where you have sub-apps and a components directories that make it easy to say "fork" the artist page by copying the sub-app and splitting between the two at a routing level. The co-location of files also makes it easy to experiment and drop old code. I also think this provides obvious "escape hatches" for when one finds themselves fighting the React/Relay/etc. stack, e.g. they could implement a sub-app that does more vanilla Express stuff or introduces a new approach to UI suited to that edge case need.
Not sure an issue is the right format to leave my thoughts on this, but I'll quickly jot them down here:
if (module.hot)
clutter the code too)fetch().then(() => res.send(ReactComponent))
code. I guess the component portability/static analysis?👍 👍 👍 exciting stuff!!
I decided that I do want to see how source compatible components could be between web and mobile, so I’ve started porting some Emission components. #16
The universal/rehydratio issues should be solvable. In fact, there’s a PR up that switches the underlying styling lib to JSS, which I have already verified to work well in a universal app. necolas/react-native-web#304
This is something handled by a Haste Map in Jest.
That said - flow does have something for this:
npm run flow -- get-imports app/containers/artist/index.js
> [email protected] flow /Users/orta/dev/js/apps/relational-theory
> flow "get-imports" "app/containers/artist/index.js"
Imports for module 'app/containers/artist/index.js':
/Users/orta/dev/js/apps/relational-theory/data/graphql-export.flow.js@/Users/orta/dev/js/apps/relational-theory/app/containers/artist/index.js:6:33,6:67
/Users/orta/dev/js/apps/relational-theory/app/containers/artist/components/header.js@/Users/orta/dev/js/apps/relational-theory/app/containers/artist/index.js:5:26,5:46
react-relay@/Users/orta/dev/js/apps/relational-theory/app/containers/artist/index.js:4:19,4:31
react@/Users/orta/dev/js/apps/relational-theory/app/containers/artist/index.js:13:7,13:11
The way we currently embed the Relay data of the server-side fetch into the rendered html is unsafe and could open us up to a user embedding html into our data that then could be used as an attack vector.
This tool does the job, but there might be an even simpler alternative https://github.com/yahoo/serialize-javascript
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.