1
0
Fork 1
mirror of https://github.com/SomboChea/ui synced 2024-05-21 02:41:36 +07:00
verdaccio-ui/src/index.js
Priscila Oliveira e2d478d65b initial commit
2019-02-03 17:04:42 +01:00

25 lines
422 B
JavaScript

import React from "react";
import ReactDOM from "react-dom";
import { AppContainer } from "react-hot-loader";
import App from "./app";
const rootNode = document.getElementById("root");
const renderApp = Component => {
ReactDOM.render(
<AppContainer>
<Component />
</AppContainer>,
rootNode
);
};
renderApp(App);
if (module.hot) {
module.hot.accept("./app", () => {
renderApp(App);
});
}