made with esnextbin
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from 'react'; | |
class Test extends Component { | |
render() { | |
return ( | |
<div> | |
Wowowow ' this is fun | |
</div> | |
); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Component = React.createClass({ | |
render: function() { | |
return( | |
<div> | |
Conor's my name | |
</div> | |
); | |
} | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Whatever extends Component { | |
render() { | |
return ( | |
<div>Wow's this is cool</div> | |
); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* The reason for this is just a thought exercise | |
* often people(myself super included) are so confused | |
* when trying something new, but breaking it down | |
* to it's simplest existence can be the best way to understand | |
*/ | |
function createStore(reducer, initState) { | |
let state = initState; | |
let subscribers = []; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* In this version without use strict declaration 'SyntaxError: Identifier 'text' has already been declared' is given | |
*/ | |
const http = require('http'); | |
const hostname = 'localhost'; | |
const port = 2001; | |
http.createServer((req, res) => { | |
if (req.url === '/favicon.ico') { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import { render } from 'react-dom'; | |
import SyntaxHighlighter from 'react-syntax-highlighter'; | |
import { docco } from 'react-syntax-highlighter/dist/styles' | |
import markdown from 'markdown'; | |
class X extends React.Component { | |
render() { | |
return ( | |
<SyntaxHighlighter language='javascript' style={docco}> |
made with esnextbin
made with esnextbin
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* node will be null */ | |
function Input() { | |
return <input />; | |
} | |
function InputContainer() { | |
return <div><Input ref={node => console.log(node)} /></div>; | |
} | |
/* node will be vnode instance */ |
OlderNewer