I want to add the Twitter widget into React, but I don\'t know where to start or how to do it. I am very new to React JS.
Here is the HTML version of the code:
This works for me!
Please note that I use React v0.14 and ECMAScript 2015 (aka ES6) with Babel.
index.html (after body tag):
Twitter component:
const Twitter = () => (
);
Some React Component (that uses Twitter button):
class SomeReactComponent extends Component {
constructor(props) {
super(props);
}
render() {
return (
);
}
}
Or if you want to have a customized button, you can simply do this:
const Twitter = () => (
);