Skip to content

Instantly share code, notes, and snippets.

@jonathanmeaney
Created March 18, 2018 14:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jonathanmeaney/a88d696129edde38d6538f28720f07e1 to your computer and use it in GitHub Desktop.
Save jonathanmeaney/a88d696129edde38d6538f28720f07e1 to your computer and use it in GitHub Desktop.
import ReactDOM from 'react-dom';
import React from 'react';
import SimpleComponent from 'components/simple-component';
// Wait until the HTML DOM is full loaded, then render the react component
document.addEventListener('DOMContentLoaded', () => {
ReactDOM.render(<SimpleComponent />, document.querySelector('#app'));
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment