Answer the question
In order to leave comments, you need to log in
How to build js modules (webpack)?
Hello.
index.js
import React from 'react';
import ReactDOM from 'react-dom';
import App from './containers/app';
ReactDOM.render(
<App/>,
document.getElementById('app')
);
import React from 'react';
import ReactDOM from 'react-dom';
const App = requery('app');
ReactDOM.render(
<App/>,
document.getElementById('app')
);
Answer the question
In order to leave comments, you need to log in
https://webpack.github.io/docs/code-splitting.html
This code will not work directly, because automatically downloading an additional file is an asynchronous action.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question