react-loadable

webpack 4 react loadable is not spliting vendor base on chucking point

强颜欢笑 提交于 2019-12-06 11:49:01
问题 I am currently using webpack 4 with react loadable to create chunks. It actually chunks depends on the break point. However, vendor size remains same. React loadable is not supporting webpack 4 yet ? or I am missing some setup ? css actually seems to splited into the chunk, though { output: { path: 'tothe path', publicPath: `/publicPath/`, filename: '[name] + '.js', chunkFilename: '[name]', }, resolve: { extensions: ['.js', '.json', '.css'], alias: aliases }, stats: { warnings: false,

Name webpack chunks from react-loadable

两盒软妹~` 提交于 2019-12-05 11:04:55
问题 I've successfully added react-loadable library in my project to enable code splitting, the only problem I've found is that the chunks generated by webpack are not named, they are given integer names. My code for react-loadable use is const AppRootLoadable = Loadable({ loader: () => import(/* webpackChunkName: "app" */ './App'), loading: () => null, render(loaded) { const Component = loaded.default; return <Component />; }, }); I've added the comment to tell webpack 3 that I want this chunk to

React-Loadable SSR with Webpack 4 and Babel 7

醉酒当歌 提交于 2019-12-04 13:11:56
问题 Does server-side rendering with react-loadable work with Webpack 4 and Babel 7? I've been unable to get it working successfully while following the instructions. After following just the client-side steps, Webpack correctly outputs separate chunks for each loadable component and this is reflected when I load the page in the browser (ie: the chunks are lazy-loaded). After following all the SSR steps, however, the server throws the following error: Error: Not supported at loader (/Projects/test

React-Loadable SSR with Webpack 4 and Babel 7

大城市里の小女人 提交于 2019-12-03 08:21:32
Does server-side rendering with react-loadable work with Webpack 4 and Babel 7? I've been unable to get it working successfully while following the instructions . After following just the client-side steps, Webpack correctly outputs separate chunks for each loadable component and this is reflected when I load the page in the browser (ie: the chunks are lazy-loaded). After following all the SSR steps, however, the server throws the following error: Error: Not supported at loader (/Projects/test-project/web/routes/index.js:50:15) at load (/Projects/test-project/web/node_modules/react-loadable