Skip to content

Commit

Permalink
[chore] it's not necessary to make chunks when running the examples.
Browse files Browse the repository at this point in the history
  • Loading branch information
diasbruno committed Dec 9, 2019
1 parent eb20444 commit aa822be
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 20 deletions.
3 changes: 1 addition & 2 deletions examples/basic/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ <h2>an accessible React modal dialog component</h2>
</header>
<div id="example" class="padbox"></div>
<a target="_top" href="https://github.com/reactjs/react-modal"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://github-camo.global.ssl.fastly.net/a6677b08c955af8400f44c6298f40e7d19cc5b2d/68747470733a2f2f73332e616d617a6f6e6177732e636f6d2f6769746875622f726962626f6e732f666f726b6d655f72696768745f677261795f3664366436642e706e67" alt="Fork me on GitHub" data-canonical-src="https://s3.amazonaws.com/github/ribbons/forkme_right_gray_6d6d6d.png"></a>
<script src="../__build__/shared.js"></script>
<script src="../__build__/basic.js"></script>
<script src="../__build__/basic.js" type="application/javascript"></script>
</body>
</html>
3 changes: 1 addition & 2 deletions examples/bootstrap/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ <h2>an accessible React modal dialog component</h2>
</header>
<div id="example" class="padbox"></div>
<a target="_top" href="https://github.com/reactjs/react-modal"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://github-camo.global.ssl.fastly.net/a6677b08c955af8400f44c6298f40e7d19cc5b2d/68747470733a2f2f73332e616d617a6f6e6177732e636f6d2f6769746875622f726962626f6e732f666f726b6d655f72696768745f677261795f3664366436642e706e67" alt="Fork me on GitHub" data-canonical-src="https://s3.amazonaws.com/github/ribbons/forkme_right_gray_6d6d6d.png"></a>
<script src="../__build__/shared.js"></script>
<script src="../__build__/bootstrap.js"></script>
<script type="application/javascript" src="/__build__/bootstrap.js"></script>
</body>
</html>
17 changes: 1 addition & 16 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,35 +24,20 @@ function buildEntries() {

module.exports = {
mode: 'development',

entry: buildEntries(),

output: {
filename: '[name].js',
chunkFilename: '[id].chunk.js',
path: path.resolve(__dirname, './examples/__build__'),
publicPath: '/__build__/'
},

module: {
rules: [
{ test: /\.js$/, exclude: /node_modules/, use: { loader: 'babel-loader' } }
]
},

resolve: {
alias: {
"react-modal": path.resolve(__dirname, "./src")
}
},

optimization: {
splitChunks: {
chunks: 'all'
}
},

plugins: [
new webpack.LoaderOptionsPlugin({ debug: true })
]
}
};

0 comments on commit aa822be

Please sign in to comment.