Comments (5)
Related and possible solution: facebook/react#944
from react-future.
Another possible solution would be to allow a spread operator in objects and JSX. As described in #6
var x = <div {...this.props} className="foo" />;
Desugars to:
var x = React.DOM.div({...this.props, className: 'foo' });
Which desugars to:
var x = React.DOM.div(Object.append({}, this.props, { className: 'foo' }));
from react-future.
Another possible (general) solution:
Start using react:
namespaced attributes for react-specific props. This keeps us in the realm of XML, solves the "having framework-imposed attributes collides with app props" problem once and for all (just use the react:
namespace), and doesn't require yet-to-be-proposed new-language-feature familiarity to understand the meaning at first glance.
from react-future.
This is already done and released in 0.12. Yay!
from react-future.
So cool looking back at old PR's/issues and see this implemented 😄
from react-future.
Related Issues (20)
- Flux over the Worker HOT 6
- working around with specificity and autoprefixer HOT 6
- Web Worker Rendering Idea HOT 3
- Support memoization of component functions during render phase HOT 16
- Discuss Conditional JSX Expression HOT 32
- Attempt to improve "Returning state" section HOT 12
- Knowing which of these made it into 0.14 HOT 1
- Lifecycle methods: drop the 'component'. just 'willMount'. it's cleaner HOT 16
- Is there any plan of implementing in webgl mode? HOT 1
- Passing styles around should be discouraged HOT 1
- Generators for async sequences
- Classes - 1 HOT 1
- Cached Data
- Killing React.createElement HOT 1
- React compiling down to raw application code HOT 24
- Consider allowing attribute logic HOT 47
- Stateless Functions are already implemented
- React as a Specification
- App breaks if i try to directly access the url - With Error - Choose is not defined
- Add new properties: `classNames` and `styles`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-future.