mirror of https://github.com/webpack/webpack.git
change output from examples for js/ to dist/
This commit is contained in:
parent
273f147dae
commit
bc7725c668
|
|
@ -4,7 +4,7 @@
|
|||
/test/fixtures/temp-cache-fixture
|
||||
/benchmark/js
|
||||
/benchmark/fixtures
|
||||
/examples/**/js
|
||||
/examples/**/dist
|
||||
/coverage
|
||||
.DS_Store
|
||||
*.log
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ module.exports = {
|
|||
pageC: "./pageC"
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].bundle.js",
|
||||
chunkFilename: "[id].chunk.js"
|
||||
},
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ module.exports = {
|
|||
pageC: "./pageC"
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].bundle.js",
|
||||
chunkFilename: "[id].chunk.js"
|
||||
},
|
||||
|
|
|
|||
|
|
@ -12,9 +12,9 @@ const async = require("async");
|
|||
|
||||
const extraArgs = "";
|
||||
|
||||
const targetArgs = global.NO_TARGET_ARGS ? "" : " ./example.js -o js/output.js ";
|
||||
const targetArgs = global.NO_TARGET_ARGS ? "" : " ./example.js -o dist/output.js ";
|
||||
const displayReasons = global.NO_REASONS ? "" : " --display-reasons --display-used-exports --display-provided-exports";
|
||||
const commonArgs = `--display-chunks --display-max-modules 99999 --display-origins --display-entrypoints --output-public-path "js/" ${extraArgs} ${targetArgs}`;
|
||||
const commonArgs = `--display-chunks --display-max-modules 99999 --display-origins --display-entrypoints --output-public-path "dist/" ${extraArgs} ${targetArgs}`;
|
||||
|
||||
let readme = fs.readFileSync(require("path").join(process.cwd(), "template.md"), "utf-8");
|
||||
|
||||
|
|
@ -23,9 +23,9 @@ const doCompileAndReplace = (args, prefix, callback) => {
|
|||
callback();
|
||||
return;
|
||||
}
|
||||
if(fs.existsSync("js"))
|
||||
for(const file of fs.readdirSync("js"))
|
||||
fs.unlinkSync(`js/${file}`);
|
||||
if(fs.existsSync("dist"))
|
||||
for(const file of fs.readdirSync("dist"))
|
||||
fs.unlinkSync(`dist/${file}`);
|
||||
cp.exec(`node ${path.resolve(__dirname, "../bin/webpack.js")} ${args} ${displayReasons} ${commonArgs}`, (error, stdout, stderr) => {
|
||||
if(stderr)
|
||||
console.log(stderr);
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ module.exports = {
|
|||
common: ["./vendor"] // optional
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].[chunkhash].js",
|
||||
chunkFilename: "[chunkhash].js"
|
||||
},
|
||||
|
|
@ -63,19 +63,19 @@ module.exports = {
|
|||
|
||||
<!-- inlined minimized file "manifest.[chunkhash].js" -->
|
||||
<script>
|
||||
!function(e){function r(r){for(var n,u,i,s=r[0],l=r[1],p=r[2],f=0,d=[];f<s.length;f++)u=s[f],o[u]&&d.push(o[u][0]),o[u]=0;for(n in l)Object.prototype.hasOwnProperty.call(l,n)&&(e[n]=l[n]);for(c&&c(r);d.length;)d.shift()();for(a.push.apply(a,p||[]),f=0;f<a.length;f++){for(var h=a[f],v=!0,g=1;g<h.length;g++){var m=h[g];0!==o[m]&&(v=!1)}v&&(a.splice(f--,1),i=t(t.s=h[0]))}return i}function t(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var n={},o={4:0},a=[];t.e=function(e){var r=[],n=o[e];if(0!==n)if(n)r.push(n[2]);else{var a=new Promise(function(r,t){n=o[e]=[r,t]});r.push(n[2]=a);var u=document.getElementsByTagName("head")[0],c=document.createElement("script");c.charset="utf-8",c.timeout=12e4,t.nc&&c.setAttribute("nonce",t.nc),c.src=t.p+""+{0:"19a84e789378731c8460",1:"4f0e85908244254bb448",2:"b94c93d31c5a9a6a8fe7",3:"59214344cd83683ae9d1"}[e]+".js";var i=setTimeout(function(){s({type:"timeout",target:c})},12e4);c.onerror=c.onload=s;function s(r){c.onerror=c.onload=null,clearTimeout(i);var t=o[e];if(0!==t){if(t){var n=r&&("load"===r.type?"missing":r.type),a=r&&r.target&&r.target.src,u=new Error("Loading chunk "+e+" failed.\n("+n+": "+a+")");u.type=n,u.request=a,t[1](u)}o[e]=void 0}}u.appendChild(c)}return Promise.all(r)},t.m=e,t.c=n,t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.r=function(e){Object.defineProperty(e,"__esModule",{value:!0})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},t.p="js/",t.oe=function(e){throw console.error(e),e};var u=window.webpackJsonp=window.webpackJsonp||[],c=u.push.bind(u);u.push=r,u=u.slice();for(var i=0;i<u.length;i++)r(u[i])}([]);
|
||||
!function(e){function r(r){for(var n,i,c,s=r[0],l=r[1],p=r[2],f=0,d=[];f<s.length;f++)i=s[f],o[i]&&d.push(o[i][0]),o[i]=0;for(n in l)Object.prototype.hasOwnProperty.call(l,n)&&(e[n]=l[n]);for(u&&u(r);d.length;)d.shift()();for(a.push.apply(a,p||[]),f=0;f<a.length;f++){for(var h=a[f],v=!0,g=1;g<h.length;g++){var m=h[g];0!==o[m]&&(v=!1)}v&&(a.splice(f--,1),c=t(t.s=h[0]))}return c}function t(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var n={},o={4:0},a=[];t.e=function(e){var r=[],n=o[e];if(0!==n)if(n)r.push(n[2]);else{var a=new Promise(function(r,t){n=o[e]=[r,t]});r.push(n[2]=a);var i=document.getElementsByTagName("head")[0],u=document.createElement("script");u.charset="utf-8",u.timeout=12e4,t.nc&&u.setAttribute("nonce",t.nc),u.src=t.p+""+{0:"19a84e789378731c8460",1:"4f0e85908244254bb448",2:"b94c93d31c5a9a6a8fe7",3:"59214344cd83683ae9d1"}[e]+".js";var c=setTimeout(function(){s({type:"timeout",target:u})},12e4);u.onerror=u.onload=s;function s(r){u.onerror=u.onload=null,clearTimeout(c);var t=o[e];if(0!==t){if(t){var n=r&&("load"===r.type?"missing":r.type),a=r&&r.target&&r.target.src,i=new Error("Loading chunk "+e+" failed.\n("+n+": "+a+")");i.type=n,i.request=a,t[1](i)}o[e]=void 0}}i.appendChild(u)}return Promise.all(r)},t.m=e,t.c=n,t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.r=function(e){Object.defineProperty(e,"__esModule",{value:!0})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},t.p="dist/",t.oe=function(e){throw console.error(e),e};var i=window.webpackJsonp=window.webpackJsonp||[],u=i.push.bind(i);i.push=r,i=i.slice();for(var c=0;c<i.length;c++)r(i[c])}([]);
|
||||
</script>
|
||||
|
||||
<!-- optional when using the CommonChunkPlugin for vendor modules -->
|
||||
<script src="js/common.[chunkhash].js"></script>
|
||||
<script src="dist/common.[chunkhash].js"></script>
|
||||
|
||||
<script src="js/main.[chunkhash].js"></script>
|
||||
<script src="dist/main.[chunkhash].js"></script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
```
|
||||
|
||||
# js/common.[chunkhash].js
|
||||
# dist/common.[chunkhash].js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[1],[
|
||||
|
|
@ -110,7 +110,7 @@ module.exports = __webpack_require__(/*! ./vendor */1);
|
|||
],[[4,4,1]]]);
|
||||
```
|
||||
|
||||
# js/main.[chunkhash].js
|
||||
# dist/main.[chunkhash].js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[0],[
|
||||
|
|
@ -146,7 +146,7 @@ Version: webpack next
|
|||
common.[chunkhash].js 727 bytes 1 [emitted] common
|
||||
b71c088662b7b530c545.js 264 bytes 2 [emitted]
|
||||
f6eb6a4d15b19e593a54.js 264 bytes 3 [emitted]
|
||||
manifest.[chunkhash].js 7.15 KiB 4 [emitted] manifest
|
||||
manifest.[chunkhash].js 7.16 KiB 4 [emitted] manifest
|
||||
Entrypoint main = manifest.[chunkhash].js common.[chunkhash].js main.[chunkhash].js
|
||||
Entrypoint common = manifest.[chunkhash].js common.[chunkhash].js
|
||||
chunk {0} main.[chunkhash].js (main) 90 bytes {1} [initial] [rendered]
|
||||
|
|
|
|||
|
|
@ -36,28 +36,28 @@ The configuration required for this is:
|
|||
|
||||
<!-- inlined minimized file "manifest.[chunkhash].js" -->
|
||||
<script>
|
||||
{{production:js/manifest.chunkhash.js}}
|
||||
{{production:dist/manifest.chunkhash.js}}
|
||||
</script>
|
||||
|
||||
<!-- optional when using the CommonChunkPlugin for vendor modules -->
|
||||
<script src="js/common.[chunkhash].js"></script>
|
||||
<script src="dist/common.[chunkhash].js"></script>
|
||||
|
||||
<script src="js/main.[chunkhash].js"></script>
|
||||
<script src="dist/main.[chunkhash].js"></script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
```
|
||||
|
||||
# js/common.[chunkhash].js
|
||||
# dist/common.[chunkhash].js
|
||||
|
||||
``` javascript
|
||||
{{js/common.chunkhash.js}}
|
||||
{{dist/common.chunkhash.js}}
|
||||
```
|
||||
|
||||
# js/main.[chunkhash].js
|
||||
# dist/main.[chunkhash].js
|
||||
|
||||
``` javascript
|
||||
{{js/main.chunkhash.js}}
|
||||
{{dist/main.chunkhash.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ module.exports = {
|
|||
common: ["./vendor"] // optional
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].chunkhash.js",
|
||||
chunkFilename: "[chunkhash].js"
|
||||
},
|
||||
|
|
|
|||
|
|
@ -62,11 +62,11 @@ module.exports = {
|
|||
};
|
||||
```
|
||||
|
||||
# js/style.css
|
||||
# dist/style.css
|
||||
|
||||
``` javascript
|
||||
body {
|
||||
background: url(js/ce21cbdd9b894e6af794813eb3fdaf60.png);
|
||||
background: url(dist/ce21cbdd9b894e6af794813eb3fdaf60.png);
|
||||
}
|
||||
```
|
||||
|
||||
|
|
@ -81,7 +81,7 @@ Version: webpack next
|
|||
ce21cbdd9b894e6af794813eb3fdaf60.png 119 bytes [emitted]
|
||||
0.output.js 2.33 KiB 0 [emitted]
|
||||
output.js 22.4 KiB 1 [emitted] main
|
||||
style.css 71 bytes 1 [emitted] main
|
||||
style.css 73 bytes 1 [emitted] main
|
||||
Entrypoint main = output.js style.css
|
||||
chunk {0} 0.output.js 1.34 KiB {1} [rendered]
|
||||
> [1] ./example.js 2:0-20
|
||||
|
|
@ -120,7 +120,7 @@ Version: webpack next
|
|||
ce21cbdd9b894e6af794813eb3fdaf60.png 119 bytes [emitted]
|
||||
0.output.js 403 bytes 0 [emitted]
|
||||
output.js 7.04 KiB 1 [emitted] main
|
||||
style.css 71 bytes 1 [emitted] main
|
||||
style.css 73 bytes 1 [emitted] main
|
||||
Entrypoint main = output.js style.css
|
||||
chunk {0} 0.output.js 1.34 KiB {1} [rendered]
|
||||
> [1] ./example.js 2:0-20
|
||||
|
|
|
|||
|
|
@ -29,10 +29,10 @@
|
|||
{{webpack.config.js}}
|
||||
```
|
||||
|
||||
# js/style.css
|
||||
# dist/style.css
|
||||
|
||||
``` javascript
|
||||
{{js/style.css}}
|
||||
{{dist/style.css}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ getTemplate("b", function(b) {
|
|||
});
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -173,7 +173,7 @@ getTemplate("b", function(b) {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -217,7 +217,7 @@ getTemplate("b", function(b) {
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[0],[
|
||||
|
|
|
|||
|
|
@ -4,16 +4,16 @@
|
|||
{{example.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/0.output.js}}
|
||||
{{dist/0.output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ getTemplate("b", function(b) {
|
|||
});
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -173,7 +173,7 @@ getTemplate("b", function(b) {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -217,7 +217,7 @@ getTemplate("b", function(b) {
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[0],[
|
||||
|
|
|
|||
|
|
@ -4,16 +4,16 @@
|
|||
{{example.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/0.output.js}}
|
||||
{{dist/0.output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ module.exports = "It works";
|
|||
```
|
||||
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -176,7 +176,7 @@ module.exports = "It works";
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -236,7 +236,7 @@ __webpack_require__(/*! bundle-loader!./file.js */ 0)(function(fileJsExports) {
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[0],{
|
||||
|
|
@ -285,7 +285,7 @@ Hash: 0a1b2c3d4e5f6a7b8c9d
|
|||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
0.output.js 98 bytes 0 [emitted]
|
||||
output.js 1.78 KiB 1 [emitted] main
|
||||
output.js 1.79 KiB 1 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} 0.output.js 28 bytes {1} [rendered]
|
||||
> [0] (webpack)/node_modules/bundle-loader!./file.js 7:0-14:2
|
||||
|
|
|
|||
|
|
@ -15,16 +15,16 @@ The bundle loader is used to create a wrapper module for `file.js` that loads th
|
|||
```
|
||||
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/0.output.js}}
|
||||
{{dist/0.output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ Promise.all([loadC("1"), loadC("2")]).then(function(arr) {
|
|||
```
|
||||
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -184,7 +184,7 @@ Promise.all([loadC("1"), loadC("2")]).then(function(arr) {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
|
|||
|
|
@ -13,10 +13,10 @@ Providing dynamic expressions to `import` is possible. The same limits as with d
|
|||
```
|
||||
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ var foo = "foo";
|
|||
export default foo;
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -202,7 +202,7 @@ export default foo;
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -321,7 +321,7 @@ Version: webpack next
|
|||
0.output.js 436 bytes 0 [emitted]
|
||||
1.output.js 445 bytes 1 [emitted]
|
||||
2.output.js 439 bytes 2 [emitted]
|
||||
output.js 8.19 KiB 3 [emitted] main
|
||||
output.js 8.2 KiB 3 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} 0.output.js 41 bytes {3} [rendered]
|
||||
[0] ./templates/foo.js 41 bytes {0} [optional] [built]
|
||||
|
|
|
|||
|
|
@ -22,10 +22,10 @@ All templates are of this pattern:
|
|||
{{templates/foo.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ var foo = "foo";
|
|||
export default foo;
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -191,7 +191,7 @@ export default foo;
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
|
|||
|
|
@ -18,10 +18,10 @@ All templates are of this pattern:
|
|||
{{templates/foo.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ var foo = "foo";
|
|||
export default foo;
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -191,7 +191,7 @@ export default foo;
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -336,7 +336,7 @@ Version: webpack next
|
|||
0.output.js 114 bytes 0 [emitted] chunk-bar-baz2
|
||||
1.output.js 115 bytes 1 [emitted] chunk-bar-baz0
|
||||
2.output.js 113 bytes 2 [emitted] chunk-foo
|
||||
output.js 2.11 KiB 3 [emitted] main
|
||||
output.js 2.12 KiB 3 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} 0.output.js (chunk-bar-baz2) 41 bytes {3} [rendered]
|
||||
[1] ./templates/baz.js 41 bytes {0} [optional] [built]
|
||||
|
|
|
|||
|
|
@ -18,10 +18,10 @@ All templates are of this pattern:
|
|||
{{templates/foo.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ require.ensure(["c"], function(require) {
|
|||
```
|
||||
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -195,7 +195,7 @@ require.ensure(["c"], function(require) {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -254,7 +254,7 @@ __webpack_require__.e(/*! require.ensure */ 0).then((function(require) {
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[0],[
|
||||
|
|
|
|||
|
|
@ -31,22 +31,22 @@ You can see that chunks are loaded via JSONP. The additional chunks are pretty s
|
|||
```
|
||||
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/0.output.js}}
|
||||
{{dist/0.output.js}}
|
||||
```
|
||||
|
||||
Minimized
|
||||
|
||||
``` javascript
|
||||
{{production:js/0.output.js}}
|
||||
{{production:dist/0.output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ console.log "yeah coffee-script"
|
|||
module.exports = 42
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -92,7 +92,7 @@ module.exports = 42
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -154,7 +154,7 @@ module.exports = 42;
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
output.js 3.33 KiB 0 [emitted] main
|
||||
output.js 3.34 KiB 0 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} output.js (main) 206 bytes [entry] [rendered]
|
||||
> main [0] ./example.js
|
||||
|
|
@ -173,7 +173,7 @@ chunk {0} output.js (main) 206 bytes [entry] [rendered]
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
output.js 706 bytes 0 [emitted] main
|
||||
output.js 708 bytes 0 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} output.js (main) 206 bytes [entry] [rendered]
|
||||
> main [2] ./example.js
|
||||
|
|
|
|||
|
|
@ -17,10 +17,10 @@
|
|||
{{cup2.coffee}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ module.exports = {
|
|||
// common: []
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
@ -61,7 +61,7 @@ module.exports = {
|
|||
};
|
||||
```
|
||||
|
||||
# js/vendor.js
|
||||
# dist/vendor.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -234,7 +234,7 @@ module.exports = {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -290,7 +290,7 @@ module.exports = "vendor2";
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/common.js
|
||||
# dist/common.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[4],{
|
||||
|
|
@ -320,7 +320,7 @@ module.exports = "utility3";
|
|||
}]);
|
||||
```
|
||||
|
||||
# js/pageA.js
|
||||
# dist/pageA.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[1],[
|
||||
|
|
@ -353,7 +353,7 @@ module.exports = "utility1";
|
|||
],[[3,0,4,1]]]);
|
||||
```
|
||||
|
||||
# js/pageB.js
|
||||
# dist/pageB.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[2],{
|
||||
|
|
@ -375,7 +375,7 @@ module.exports = "pageB";
|
|||
},[[6,0,4,2]]]);
|
||||
```
|
||||
|
||||
# js/pageC.js
|
||||
# dist/pageC.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[3],{
|
||||
|
|
@ -456,7 +456,7 @@ common.js 132 bytes 0 [emitted] common
|
|||
pageC.js 119 bytes 1 [emitted] pageC
|
||||
pageB.js 119 bytes 2 [emitted] pageB
|
||||
pageA.js 157 bytes 3 [emitted] pageA
|
||||
vendor.js 1.82 KiB 4 [emitted] vendor
|
||||
vendor.js 1.83 KiB 4 [emitted] vendor
|
||||
Entrypoint vendor = vendor.js
|
||||
Entrypoint pageA = vendor.js common.js pageA.js
|
||||
Entrypoint pageB = vendor.js common.js pageB.js
|
||||
|
|
|
|||
|
|
@ -37,34 +37,34 @@ With this bundle configuration, you would load your third party libraries, then
|
|||
{{webpack.config.js}}
|
||||
```
|
||||
|
||||
# js/vendor.js
|
||||
# dist/vendor.js
|
||||
|
||||
``` javascript
|
||||
{{js/vendor.js}}
|
||||
{{dist/vendor.js}}
|
||||
```
|
||||
|
||||
# js/common.js
|
||||
# dist/common.js
|
||||
|
||||
``` javascript
|
||||
{{js/common.js}}
|
||||
{{dist/common.js}}
|
||||
```
|
||||
|
||||
# js/pageA.js
|
||||
# dist/pageA.js
|
||||
|
||||
``` javascript
|
||||
{{js/pageA.js}}
|
||||
{{dist/pageA.js}}
|
||||
```
|
||||
|
||||
# js/pageB.js
|
||||
# dist/pageB.js
|
||||
|
||||
``` javascript
|
||||
{{js/pageB.js}}
|
||||
{{dist/pageB.js}}
|
||||
```
|
||||
|
||||
# js/pageC.js
|
||||
# dist/pageC.js
|
||||
|
||||
``` javascript
|
||||
{{js/pageC.js}}
|
||||
{{dist/pageC.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ module.exports = {
|
|||
// common: []
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ module.exports = [
|
|||
main: ["./example.js"]
|
||||
},
|
||||
output: {
|
||||
path: path.resolve(__dirname, "js"),
|
||||
path: path.resolve(__dirname, "dist"),
|
||||
filename: "output.js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
@ -114,7 +114,7 @@ module.exports = [
|
|||
main: ["./example.js"]
|
||||
},
|
||||
output: {
|
||||
path: path.resolve(__dirname, "js"),
|
||||
path: path.resolve(__dirname, "dist"),
|
||||
filename: "asyncoutput.js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
@ -133,7 +133,7 @@ module.exports = [
|
|||
];
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -292,7 +292,7 @@ module.exports = [
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -363,7 +363,7 @@ module.exports = function() {
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[0],{
|
||||
|
|
@ -388,7 +388,7 @@ module.exports = function() {
|
|||
}]);
|
||||
```
|
||||
|
||||
# js/1.output.js
|
||||
# dist/1.output.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[1],{
|
||||
|
|
@ -414,7 +414,7 @@ module.exports = function() {
|
|||
}]);
|
||||
```
|
||||
|
||||
# js/2.output.js
|
||||
# dist/2.output.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[2],{
|
||||
|
|
@ -439,7 +439,7 @@ module.exports = function() {
|
|||
}]);
|
||||
```
|
||||
|
||||
# js/asyncoutput.js
|
||||
# dist/asyncoutput.js
|
||||
|
||||
``` javascript
|
||||
/******/ (function(modules) { // webpackBootstrap
|
||||
|
|
@ -596,7 +596,7 @@ module.exports = function() {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -649,7 +649,7 @@ module.exports = __webpack_require__(/*! ./example.js */0);
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/0.asyncoutput.js
|
||||
# dist/0.asyncoutput.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[0],{
|
||||
|
|
@ -671,7 +671,7 @@ module.exports = function() {
|
|||
}]);
|
||||
```
|
||||
|
||||
# js/1.asyncoutput.js
|
||||
# dist/1.asyncoutput.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[1],{
|
||||
|
|
@ -697,7 +697,7 @@ module.exports = function() {
|
|||
}]);
|
||||
```
|
||||
|
||||
# js/2.asyncoutput.js
|
||||
# dist/2.asyncoutput.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[2],{
|
||||
|
|
@ -722,7 +722,7 @@ module.exports = function() {
|
|||
}]);
|
||||
```
|
||||
|
||||
# js/3.asyncoutput.js
|
||||
# dist/3.asyncoutput.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[3],{
|
||||
|
|
@ -829,7 +829,7 @@ Child
|
|||
0.output.js 138 bytes 0 [emitted]
|
||||
1.output.js 176 bytes 1 [emitted]
|
||||
2.output.js 138 bytes 2 [emitted]
|
||||
output.js 1.8 KiB 3 [emitted] main
|
||||
output.js 1.81 KiB 3 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} 0.output.js 142 bytes {3} [rendered]
|
||||
> [3] ./pageB.js 3:1-6:3
|
||||
|
|
|
|||
|
|
@ -55,58 +55,58 @@ You can see that webpack outputs four files/chunks:
|
|||
{{webpack.config.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/0.output.js}}
|
||||
{{dist/0.output.js}}
|
||||
```
|
||||
|
||||
# js/1.output.js
|
||||
# dist/1.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/1.output.js}}
|
||||
{{dist/1.output.js}}
|
||||
```
|
||||
|
||||
# js/2.output.js
|
||||
# dist/2.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/2.output.js}}
|
||||
{{dist/2.output.js}}
|
||||
```
|
||||
|
||||
# js/asyncoutput.js
|
||||
# dist/asyncoutput.js
|
||||
|
||||
``` javascript
|
||||
{{js/asyncoutput.js}}
|
||||
{{dist/asyncoutput.js}}
|
||||
```
|
||||
|
||||
# js/0.asyncoutput.js
|
||||
# dist/0.asyncoutput.js
|
||||
|
||||
``` javascript
|
||||
{{js/0.asyncoutput.js}}
|
||||
{{dist/0.asyncoutput.js}}
|
||||
```
|
||||
|
||||
# js/1.asyncoutput.js
|
||||
# dist/1.asyncoutput.js
|
||||
|
||||
``` javascript
|
||||
{{js/1.asyncoutput.js}}
|
||||
{{dist/1.asyncoutput.js}}
|
||||
```
|
||||
|
||||
# js/2.asyncoutput.js
|
||||
# dist/2.asyncoutput.js
|
||||
|
||||
``` javascript
|
||||
{{js/2.asyncoutput.js}}
|
||||
{{dist/2.asyncoutput.js}}
|
||||
```
|
||||
|
||||
# js/3.asyncoutput.js
|
||||
# dist/3.asyncoutput.js
|
||||
|
||||
``` javascript
|
||||
{{js/3.asyncoutput.js}}
|
||||
{{dist/3.asyncoutput.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ module.exports = [
|
|||
main: ["./example.js"]
|
||||
},
|
||||
output: {
|
||||
path: path.resolve(__dirname, "js"),
|
||||
path: path.resolve(__dirname, "dist"),
|
||||
filename: "output.js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
@ -30,7 +30,7 @@ module.exports = [
|
|||
main: ["./example.js"]
|
||||
},
|
||||
output: {
|
||||
path: path.resolve(__dirname, "js"),
|
||||
path: path.resolve(__dirname, "dist"),
|
||||
filename: "asyncoutput.js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ exports.add = function() {
|
|||
};
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -104,7 +104,7 @@ exports.add = function() {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -186,7 +186,7 @@ chunk {0} output.js (main) 329 bytes [entry] [rendered]
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
output.js 738 bytes 0 [emitted] main
|
||||
output.js 740 bytes 0 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} output.js (main) 329 bytes [entry] [rendered]
|
||||
> main [2] ./example.js
|
||||
|
|
|
|||
|
|
@ -24,10 +24,10 @@ You can also see the info messages webpack prints to console (for both normal an
|
|||
{{math.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -44,7 +44,7 @@ module.exports = {
|
|||
};
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -113,7 +113,7 @@ module.exports = {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -148,11 +148,11 @@ __webpack_require__(/*! ./style.css */ 1);
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/style.css
|
||||
# dist/style.css
|
||||
|
||||
``` css
|
||||
body {
|
||||
background: url(js/ce21cbdd9b894e6af794813eb3fdaf60.png);
|
||||
background: url(dist/ce21cbdd9b894e6af794813eb3fdaf60.png);
|
||||
}
|
||||
```
|
||||
|
||||
|
|
@ -166,7 +166,7 @@ Version: webpack next
|
|||
Asset Size Chunks Chunk Names
|
||||
ce21cbdd9b894e6af794813eb3fdaf60.png 119 bytes [emitted]
|
||||
output.js 2.97 KiB 0 [emitted] main
|
||||
style.css 69 bytes 0 [emitted] main
|
||||
style.css 71 bytes 0 [emitted] main
|
||||
Entrypoint main = output.js style.css
|
||||
chunk {0} output.js, style.css (main) 64 bytes [entry] [rendered]
|
||||
> main [0] ./example.js
|
||||
|
|
@ -194,8 +194,8 @@ Hash: 0a1b2c3d4e5f6a7b8c9d
|
|||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
ce21cbdd9b894e6af794813eb3fdaf60.png 119 bytes [emitted]
|
||||
output.js 570 bytes 0 [emitted] main
|
||||
style.css 69 bytes 0 [emitted] main
|
||||
output.js 572 bytes 0 [emitted] main
|
||||
style.css 71 bytes 0 [emitted] main
|
||||
Entrypoint main = output.js style.css
|
||||
chunk {0} output.js, style.css (main) 64 bytes [entry] [rendered]
|
||||
> main [1] ./example.js
|
||||
|
|
|
|||
|
|
@ -17,16 +17,16 @@
|
|||
{{webpack.config.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# js/style.css
|
||||
# dist/style.css
|
||||
|
||||
``` css
|
||||
{{js/style.css}}
|
||||
{{dist/style.css}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -18,13 +18,13 @@ module.exports = {
|
|||
entry: ["example-vendor"],
|
||||
output: {
|
||||
filename: "vendor.js", // best use [hash] here too
|
||||
path: path.resolve(__dirname, "js"),
|
||||
path: path.resolve(__dirname, "dist"),
|
||||
library: "vendor_lib_[hash]",
|
||||
},
|
||||
plugins: [
|
||||
new webpack.DllPlugin({
|
||||
name: "vendor_lib_[hash]",
|
||||
path: path.resolve(__dirname, "js/vendor-manifest.json"),
|
||||
path: path.resolve(__dirname, "dist/vendor-manifest.json"),
|
||||
}),
|
||||
],
|
||||
};
|
||||
|
|
@ -38,10 +38,10 @@ export function square(n) {
|
|||
}
|
||||
```
|
||||
|
||||
# js/vendor.js
|
||||
# dist/vendor.js
|
||||
|
||||
``` javascript
|
||||
var vendor_lib_05435546db8fb3868aaf =
|
||||
var vendor_lib_3312d7a9aacfa149e455 =
|
||||
```
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -110,7 +110,7 @@ var vendor_lib_05435546db8fb3868aaf =
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -153,10 +153,10 @@ function square(n) {
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/vendor-manifest.json
|
||||
# dist/vendor-manifest.json
|
||||
|
||||
``` javascript
|
||||
{"name":"vendor_lib_05435546db8fb3868aaf","content":{"../node_modules/example-vendor.js":{"id":1,"buildMeta":{"exportsType":"namespace","providedExports":["square"]}}}}
|
||||
{"name":"vendor_lib_3312d7a9aacfa149e455","content":{"../node_modules/example-vendor.js":{"id":1,"buildMeta":{"exportsType":"namespace","providedExports":["square"]}}}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
@ -166,8 +166,8 @@ function square(n) {
|
|||
```
|
||||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
vendor.js 3.3 KiB 0 [emitted] main
|
||||
Asset Size Chunks Chunk Names
|
||||
vendor.js 3.31 KiB 0 [emitted] main
|
||||
Entrypoint main = vendor.js
|
||||
chunk {0} vendor.js (main) 60 bytes [entry] [rendered]
|
||||
> main [0] dll main
|
||||
|
|
@ -183,7 +183,7 @@ chunk {0} vendor.js (main) 60 bytes [entry] [rendered]
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
vendor.js 702 bytes 0 [emitted] main
|
||||
vendor.js 704 bytes 0 [emitted] main
|
||||
Entrypoint main = vendor.js
|
||||
chunk {0} vendor.js (main) 60 bytes [entry] [rendered]
|
||||
> main [1] dll main
|
||||
|
|
|
|||
|
|
@ -18,16 +18,16 @@ A manifest is creates which includes mappings from module names to internal ids.
|
|||
{{../node_modules/example-vendor.js}}
|
||||
```
|
||||
|
||||
# js/vendor.js
|
||||
# dist/vendor.js
|
||||
|
||||
``` javascript
|
||||
{{js/vendor.js}}
|
||||
{{dist/vendor.js}}
|
||||
```
|
||||
|
||||
# js/vendor-manifest.json
|
||||
# dist/vendor-manifest.json
|
||||
|
||||
``` javascript
|
||||
{{js/vendor-manifest.json}}
|
||||
{{dist/vendor-manifest.json}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -7,13 +7,13 @@ module.exports = {
|
|||
entry: ["example-vendor"],
|
||||
output: {
|
||||
filename: "vendor.js", // best use [hash] here too
|
||||
path: path.resolve(__dirname, "js"),
|
||||
path: path.resolve(__dirname, "dist"),
|
||||
library: "vendor_lib_[hash]",
|
||||
},
|
||||
plugins: [
|
||||
new webpack.DllPlugin({
|
||||
name: "vendor_lib_[hash]",
|
||||
path: path.resolve(__dirname, "js/vendor-manifest.json"),
|
||||
path: path.resolve(__dirname, "dist/vendor-manifest.json"),
|
||||
}),
|
||||
],
|
||||
};
|
||||
|
|
|
|||
|
|
@ -14,12 +14,12 @@ module.exports = {
|
|||
entry: "./example-app",
|
||||
output: {
|
||||
filename: "app.js",
|
||||
path: path.resolve(__dirname, "js"),
|
||||
path: path.resolve(__dirname, "dist"),
|
||||
},
|
||||
plugins: [
|
||||
new webpack.DllReferencePlugin({
|
||||
context: ".",
|
||||
manifest: require("../0-vendor/js/vendor-manifest.json"), // eslint-disable-line
|
||||
manifest: require("../0-vendor/dist/vendor-manifest.json"), // eslint-disable-line
|
||||
}),
|
||||
],
|
||||
};
|
||||
|
|
@ -46,7 +46,7 @@ console.log(new square(7));
|
|||
</html>
|
||||
```
|
||||
|
||||
# js/app.js
|
||||
# dist/app.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -115,7 +115,7 @@ console.log(new square(7));
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -146,22 +146,22 @@ console.log(new example_vendor__WEBPACK_IMPORTED_MODULE_0__["square"](7));
|
|||
/***/ }),
|
||||
/* 1 */
|
||||
/*!******************************************************************************************************!*\
|
||||
!*** delegated ../node_modules/example-vendor.js from dll-reference vendor_lib_05435546db8fb3868aaf ***!
|
||||
!*** delegated ../node_modules/example-vendor.js from dll-reference vendor_lib_3312d7a9aacfa149e455 ***!
|
||||
\******************************************************************************************************/
|
||||
/*! exports provided: square */
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
module.exports = (__webpack_require__(/*! dll-reference vendor_lib_05435546db8fb3868aaf */ 2))(1);
|
||||
module.exports = (__webpack_require__(/*! dll-reference vendor_lib_3312d7a9aacfa149e455 */ 2))(1);
|
||||
|
||||
/***/ }),
|
||||
/* 2 */
|
||||
/*!**************************************************!*\
|
||||
!*** external "vendor_lib_05435546db8fb3868aaf" ***!
|
||||
!*** external "vendor_lib_3312d7a9aacfa149e455" ***!
|
||||
\**************************************************/
|
||||
/*! no static exports found */
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
module.exports = vendor_lib_05435546db8fb3868aaf;
|
||||
module.exports = vendor_lib_3312d7a9aacfa149e455;
|
||||
|
||||
/***/ })
|
||||
/******/ ]);
|
||||
|
|
@ -182,13 +182,13 @@ chunk {0} app.js (main) 182 bytes [entry] [rendered]
|
|||
[0] ./example-app.js 98 bytes {0} [built]
|
||||
[no exports]
|
||||
single entry ./example-app main
|
||||
[1] delegated ../node_modules/example-vendor.js from dll-reference vendor_lib_05435546db8fb3868aaf 42 bytes {0} [built]
|
||||
[1] delegated ../node_modules/example-vendor.js from dll-reference vendor_lib_3312d7a9aacfa149e455 42 bytes {0} [built]
|
||||
[exports: square]
|
||||
harmony side effect evaluation example-vendor [0] ./example-app.js 1:0-40
|
||||
harmony import specifier example-vendor [0] ./example-app.js 3:12-18
|
||||
harmony import specifier example-vendor [0] ./example-app.js 4:16-22
|
||||
[2] external "vendor_lib_05435546db8fb3868aaf" 42 bytes {0} [built]
|
||||
delegated source dll-reference vendor_lib_05435546db8fb3868aaf [1] delegated ../node_modules/example-vendor.js from dll-reference vendor_lib_05435546db8fb3868aaf
|
||||
[2] external "vendor_lib_3312d7a9aacfa149e455" 42 bytes {0} [built]
|
||||
delegated source dll-reference vendor_lib_3312d7a9aacfa149e455 [1] delegated ../node_modules/example-vendor.js from dll-reference vendor_lib_3312d7a9aacfa149e455
|
||||
```
|
||||
|
||||
## Production mode
|
||||
|
|
@ -197,17 +197,17 @@ chunk {0} app.js (main) 182 bytes [entry] [rendered]
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
app.js 734 bytes 0 [emitted] main
|
||||
app.js 736 bytes 0 [emitted] main
|
||||
Entrypoint main = app.js
|
||||
chunk {0} app.js (main) 182 bytes [entry] [rendered]
|
||||
> main [2] ./example-app.js
|
||||
[0] delegated ../node_modules/example-vendor.js from dll-reference vendor_lib_05435546db8fb3868aaf 42 bytes {0} [built]
|
||||
[0] delegated ../node_modules/example-vendor.js from dll-reference vendor_lib_3312d7a9aacfa149e455 42 bytes {0} [built]
|
||||
[exports: square]
|
||||
harmony side effect evaluation example-vendor [2] ./example-app.js 1:0-40
|
||||
harmony import specifier example-vendor [2] ./example-app.js 3:12-18
|
||||
harmony import specifier example-vendor [2] ./example-app.js 4:16-22
|
||||
[1] external "vendor_lib_05435546db8fb3868aaf" 42 bytes {0} [built]
|
||||
delegated source dll-reference vendor_lib_05435546db8fb3868aaf [0] delegated ../node_modules/example-vendor.js from dll-reference vendor_lib_05435546db8fb3868aaf
|
||||
[1] external "vendor_lib_3312d7a9aacfa149e455" 42 bytes {0} [built]
|
||||
delegated source dll-reference vendor_lib_3312d7a9aacfa149e455 [0] delegated ../node_modules/example-vendor.js from dll-reference vendor_lib_3312d7a9aacfa149e455
|
||||
[2] ./example-app.js 98 bytes {0} [built]
|
||||
[no exports]
|
||||
single entry ./example-app main
|
||||
|
|
|
|||
|
|
@ -20,10 +20,10 @@ The previously built vendor dll is used. The DllReferencePlugin reads the conten
|
|||
{{example.html}}
|
||||
```
|
||||
|
||||
# js/app.js
|
||||
# dist/app.js
|
||||
|
||||
``` javascript
|
||||
{{js/app.js}}
|
||||
{{dist/app.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -7,12 +7,12 @@ module.exports = {
|
|||
entry: "./example-app",
|
||||
output: {
|
||||
filename: "app.js",
|
||||
path: path.resolve(__dirname, "js"),
|
||||
path: path.resolve(__dirname, "dist"),
|
||||
},
|
||||
plugins: [
|
||||
new webpack.DllReferencePlugin({
|
||||
context: ".",
|
||||
manifest: require("../0-vendor/js/vendor-manifest.json"), // eslint-disable-line
|
||||
manifest: require("../0-vendor/dist/vendor-manifest.json"), // eslint-disable-line
|
||||
}),
|
||||
],
|
||||
};
|
||||
|
|
|
|||
|
|
@ -14,11 +14,11 @@ module.exports = {
|
|||
plugins: [
|
||||
new webpack.DllReferencePlugin({
|
||||
context: path.join(__dirname, "..", "dll"),
|
||||
manifest: require("../dll/js/alpha-manifest.json") // eslint-disable-line
|
||||
manifest: require("../dll/dist/alpha-manifest.json") // eslint-disable-line
|
||||
}),
|
||||
new webpack.DllReferencePlugin({
|
||||
scope: "beta",
|
||||
manifest: require("../dll/js/beta-manifest.json"), // eslint-disable-line
|
||||
manifest: require("../dll/dist/beta-manifest.json"), // eslint-disable-line
|
||||
extensions: [".js", ".jsx"]
|
||||
})
|
||||
]
|
||||
|
|
@ -38,7 +38,7 @@ console.log(require("beta/c"));
|
|||
console.log(require("module"));
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -107,7 +107,7 @@ console.log(require("module"));
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -139,82 +139,82 @@ console.log(__webpack_require__(/*! module */ 8));
|
|||
/***/ }),
|
||||
/* 1 */
|
||||
/*!**************************************************************************!*\
|
||||
!*** delegated ./alpha.js from dll-reference alpha_a716524c34bed97b283e ***!
|
||||
!*** delegated ./alpha.js from dll-reference alpha_100e8e712194d1301cec ***!
|
||||
\**************************************************************************/
|
||||
/*! no static exports found */
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
module.exports = (__webpack_require__(/*! dll-reference alpha_a716524c34bed97b283e */ 2))(1);
|
||||
module.exports = (__webpack_require__(/*! dll-reference alpha_100e8e712194d1301cec */ 2))(1);
|
||||
|
||||
/***/ }),
|
||||
/* 2 */
|
||||
/*!*********************************************!*\
|
||||
!*** external "alpha_a716524c34bed97b283e" ***!
|
||||
!*** external "alpha_100e8e712194d1301cec" ***!
|
||||
\*********************************************/
|
||||
/*! no static exports found */
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
module.exports = alpha_a716524c34bed97b283e;
|
||||
module.exports = alpha_100e8e712194d1301cec;
|
||||
|
||||
/***/ }),
|
||||
/* 3 */
|
||||
/*!**********************************************************************!*\
|
||||
!*** delegated ./a.js from dll-reference alpha_a716524c34bed97b283e ***!
|
||||
!*** delegated ./a.js from dll-reference alpha_100e8e712194d1301cec ***!
|
||||
\**********************************************************************/
|
||||
/*! no static exports found */
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
module.exports = (__webpack_require__(/*! dll-reference alpha_a716524c34bed97b283e */ 2))(2);
|
||||
module.exports = (__webpack_require__(/*! dll-reference alpha_100e8e712194d1301cec */ 2))(2);
|
||||
|
||||
/***/ }),
|
||||
/* 4 */
|
||||
/*!************************************************************************!*\
|
||||
!*** delegated ./beta.js from dll-reference beta_a716524c34bed97b283e ***!
|
||||
!*** delegated ./beta.js from dll-reference beta_100e8e712194d1301cec ***!
|
||||
\************************************************************************/
|
||||
/*! no static exports found */
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
module.exports = (__webpack_require__(/*! dll-reference beta_a716524c34bed97b283e */ 5))(5);
|
||||
module.exports = (__webpack_require__(/*! dll-reference beta_100e8e712194d1301cec */ 5))(5);
|
||||
|
||||
/***/ }),
|
||||
/* 5 */
|
||||
/*!********************************************!*\
|
||||
!*** external "beta_a716524c34bed97b283e" ***!
|
||||
!*** external "beta_100e8e712194d1301cec" ***!
|
||||
\********************************************/
|
||||
/*! no static exports found */
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
module.exports = beta_a716524c34bed97b283e;
|
||||
module.exports = beta_100e8e712194d1301cec;
|
||||
|
||||
/***/ }),
|
||||
/* 6 */
|
||||
/*!*********************************************************************!*\
|
||||
!*** delegated ./b.js from dll-reference beta_a716524c34bed97b283e ***!
|
||||
!*** delegated ./b.js from dll-reference beta_100e8e712194d1301cec ***!
|
||||
\*********************************************************************/
|
||||
/*! no static exports found */
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
module.exports = (__webpack_require__(/*! dll-reference beta_a716524c34bed97b283e */ 5))(6);
|
||||
module.exports = (__webpack_require__(/*! dll-reference beta_100e8e712194d1301cec */ 5))(6);
|
||||
|
||||
/***/ }),
|
||||
/* 7 */
|
||||
/*!**********************************************************************!*\
|
||||
!*** delegated ./c.jsx from dll-reference beta_a716524c34bed97b283e ***!
|
||||
!*** delegated ./c.jsx from dll-reference beta_100e8e712194d1301cec ***!
|
||||
\**********************************************************************/
|
||||
/*! no static exports found */
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
module.exports = (__webpack_require__(/*! dll-reference beta_a716524c34bed97b283e */ 5))(7);
|
||||
module.exports = (__webpack_require__(/*! dll-reference beta_100e8e712194d1301cec */ 5))(7);
|
||||
|
||||
/***/ }),
|
||||
/* 8 */
|
||||
/*!*****************************************************************************************!*\
|
||||
!*** delegated ../node_modules/module.js from dll-reference alpha_a716524c34bed97b283e ***!
|
||||
!*** delegated ../node_modules/module.js from dll-reference alpha_100e8e712194d1301cec ***!
|
||||
\*****************************************************************************************/
|
||||
/*! no static exports found */
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
module.exports = (__webpack_require__(/*! dll-reference alpha_a716524c34bed97b283e */ 2))(3);
|
||||
module.exports = (__webpack_require__(/*! dll-reference alpha_100e8e712194d1301cec */ 2))(3);
|
||||
|
||||
/***/ })
|
||||
/******/ ]);
|
||||
|
|
@ -228,31 +228,31 @@ module.exports = (__webpack_require__(/*! dll-reference alpha_a716524c34bed97b28
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
output.js 6.17 KiB 0 [emitted] main
|
||||
output.js 6.18 KiB 0 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} output.js (main) 549 bytes [entry] [rendered]
|
||||
> main [0] ./example.js
|
||||
[0] ./example.js 213 bytes {0} [built]
|
||||
single entry .\example.js main
|
||||
[1] delegated ./alpha.js from dll-reference alpha_a716524c34bed97b283e 42 bytes {0} [built]
|
||||
[1] delegated ./alpha.js from dll-reference alpha_100e8e712194d1301cec 42 bytes {0} [built]
|
||||
cjs require ../dll/alpha [0] ./example.js 1:12-35
|
||||
[2] external "alpha_a716524c34bed97b283e" 42 bytes {0} [built]
|
||||
delegated source dll-reference alpha_a716524c34bed97b283e [1] delegated ./alpha.js from dll-reference alpha_a716524c34bed97b283e
|
||||
delegated source dll-reference alpha_a716524c34bed97b283e [3] delegated ./a.js from dll-reference alpha_a716524c34bed97b283e
|
||||
delegated source dll-reference alpha_a716524c34bed97b283e [8] delegated ../node_modules/module.js from dll-reference alpha_a716524c34bed97b283e
|
||||
[3] delegated ./a.js from dll-reference alpha_a716524c34bed97b283e 42 bytes {0} [built]
|
||||
[2] external "alpha_100e8e712194d1301cec" 42 bytes {0} [built]
|
||||
delegated source dll-reference alpha_100e8e712194d1301cec [1] delegated ./alpha.js from dll-reference alpha_100e8e712194d1301cec
|
||||
delegated source dll-reference alpha_100e8e712194d1301cec [3] delegated ./a.js from dll-reference alpha_100e8e712194d1301cec
|
||||
delegated source dll-reference alpha_100e8e712194d1301cec [8] delegated ../node_modules/module.js from dll-reference alpha_100e8e712194d1301cec
|
||||
[3] delegated ./a.js from dll-reference alpha_100e8e712194d1301cec 42 bytes {0} [built]
|
||||
cjs require ../dll/a [0] ./example.js 2:12-31
|
||||
[4] delegated ./beta.js from dll-reference beta_a716524c34bed97b283e 42 bytes {0} [built]
|
||||
[4] delegated ./beta.js from dll-reference beta_100e8e712194d1301cec 42 bytes {0} [built]
|
||||
cjs require beta/beta [0] ./example.js 4:12-32
|
||||
[5] external "beta_a716524c34bed97b283e" 42 bytes {0} [built]
|
||||
delegated source dll-reference beta_a716524c34bed97b283e [4] delegated ./beta.js from dll-reference beta_a716524c34bed97b283e
|
||||
delegated source dll-reference beta_a716524c34bed97b283e [6] delegated ./b.js from dll-reference beta_a716524c34bed97b283e
|
||||
delegated source dll-reference beta_a716524c34bed97b283e [7] delegated ./c.jsx from dll-reference beta_a716524c34bed97b283e
|
||||
[6] delegated ./b.js from dll-reference beta_a716524c34bed97b283e 42 bytes {0} [built]
|
||||
[5] external "beta_100e8e712194d1301cec" 42 bytes {0} [built]
|
||||
delegated source dll-reference beta_100e8e712194d1301cec [4] delegated ./beta.js from dll-reference beta_100e8e712194d1301cec
|
||||
delegated source dll-reference beta_100e8e712194d1301cec [6] delegated ./b.js from dll-reference beta_100e8e712194d1301cec
|
||||
delegated source dll-reference beta_100e8e712194d1301cec [7] delegated ./c.jsx from dll-reference beta_100e8e712194d1301cec
|
||||
[6] delegated ./b.js from dll-reference beta_100e8e712194d1301cec 42 bytes {0} [built]
|
||||
cjs require beta/b [0] ./example.js 5:12-29
|
||||
[7] delegated ./c.jsx from dll-reference beta_a716524c34bed97b283e 42 bytes {0} [built]
|
||||
[7] delegated ./c.jsx from dll-reference beta_100e8e712194d1301cec 42 bytes {0} [built]
|
||||
cjs require beta/c [0] ./example.js 6:12-29
|
||||
[8] delegated ../node_modules/module.js from dll-reference alpha_a716524c34bed97b283e 42 bytes {0} [built]
|
||||
[8] delegated ../node_modules/module.js from dll-reference alpha_100e8e712194d1301cec 42 bytes {0} [built]
|
||||
cjs require module [0] ./example.js 8:12-29
|
||||
```
|
||||
|
||||
|
|
@ -262,29 +262,29 @@ chunk {0} output.js (main) 549 bytes [entry] [rendered]
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
output.js 970 bytes 0 [emitted] main
|
||||
output.js 972 bytes 0 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} output.js (main) 549 bytes [entry] [rendered]
|
||||
> main [8] ./example.js
|
||||
[0] external "beta_a716524c34bed97b283e" 42 bytes {0} [built]
|
||||
delegated source dll-reference beta_a716524c34bed97b283e [3] delegated ./c.jsx from dll-reference beta_a716524c34bed97b283e
|
||||
delegated source dll-reference beta_a716524c34bed97b283e [4] delegated ./b.js from dll-reference beta_a716524c34bed97b283e
|
||||
delegated source dll-reference beta_a716524c34bed97b283e [5] delegated ./beta.js from dll-reference beta_a716524c34bed97b283e
|
||||
[1] external "alpha_a716524c34bed97b283e" 42 bytes {0} [built]
|
||||
delegated source dll-reference alpha_a716524c34bed97b283e [2] delegated ../node_modules/module.js from dll-reference alpha_a716524c34bed97b283e
|
||||
delegated source dll-reference alpha_a716524c34bed97b283e [6] delegated ./a.js from dll-reference alpha_a716524c34bed97b283e
|
||||
delegated source dll-reference alpha_a716524c34bed97b283e [7] delegated ./alpha.js from dll-reference alpha_a716524c34bed97b283e
|
||||
[2] delegated ../node_modules/module.js from dll-reference alpha_a716524c34bed97b283e 42 bytes {0} [built]
|
||||
[0] external "beta_100e8e712194d1301cec" 42 bytes {0} [built]
|
||||
delegated source dll-reference beta_100e8e712194d1301cec [3] delegated ./c.jsx from dll-reference beta_100e8e712194d1301cec
|
||||
delegated source dll-reference beta_100e8e712194d1301cec [4] delegated ./b.js from dll-reference beta_100e8e712194d1301cec
|
||||
delegated source dll-reference beta_100e8e712194d1301cec [5] delegated ./beta.js from dll-reference beta_100e8e712194d1301cec
|
||||
[1] external "alpha_100e8e712194d1301cec" 42 bytes {0} [built]
|
||||
delegated source dll-reference alpha_100e8e712194d1301cec [2] delegated ../node_modules/module.js from dll-reference alpha_100e8e712194d1301cec
|
||||
delegated source dll-reference alpha_100e8e712194d1301cec [6] delegated ./a.js from dll-reference alpha_100e8e712194d1301cec
|
||||
delegated source dll-reference alpha_100e8e712194d1301cec [7] delegated ./alpha.js from dll-reference alpha_100e8e712194d1301cec
|
||||
[2] delegated ../node_modules/module.js from dll-reference alpha_100e8e712194d1301cec 42 bytes {0} [built]
|
||||
cjs require module [8] ./example.js 8:12-29
|
||||
[3] delegated ./c.jsx from dll-reference beta_a716524c34bed97b283e 42 bytes {0} [built]
|
||||
[3] delegated ./c.jsx from dll-reference beta_100e8e712194d1301cec 42 bytes {0} [built]
|
||||
cjs require beta/c [8] ./example.js 6:12-29
|
||||
[4] delegated ./b.js from dll-reference beta_a716524c34bed97b283e 42 bytes {0} [built]
|
||||
[4] delegated ./b.js from dll-reference beta_100e8e712194d1301cec 42 bytes {0} [built]
|
||||
cjs require beta/b [8] ./example.js 5:12-29
|
||||
[5] delegated ./beta.js from dll-reference beta_a716524c34bed97b283e 42 bytes {0} [built]
|
||||
[5] delegated ./beta.js from dll-reference beta_100e8e712194d1301cec 42 bytes {0} [built]
|
||||
cjs require beta/beta [8] ./example.js 4:12-32
|
||||
[6] delegated ./a.js from dll-reference alpha_a716524c34bed97b283e 42 bytes {0} [built]
|
||||
[6] delegated ./a.js from dll-reference alpha_100e8e712194d1301cec 42 bytes {0} [built]
|
||||
cjs require ../dll/a [8] ./example.js 2:12-31
|
||||
[7] delegated ./alpha.js from dll-reference alpha_a716524c34bed97b283e 42 bytes {0} [built]
|
||||
[7] delegated ./alpha.js from dll-reference alpha_100e8e712194d1301cec 42 bytes {0} [built]
|
||||
cjs require ../dll/alpha [8] ./example.js 1:12-35
|
||||
[8] ./example.js 213 bytes {0} [built]
|
||||
single entry .\example.js main
|
||||
|
|
|
|||
|
|
@ -16,10 +16,10 @@ This is the _user_ bundle, which uses the manifest from [dll-reference example](
|
|||
{{example.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -5,11 +5,11 @@ module.exports = {
|
|||
plugins: [
|
||||
new webpack.DllReferencePlugin({
|
||||
context: path.join(__dirname, "..", "dll"),
|
||||
manifest: require("../dll/js/alpha-manifest.json") // eslint-disable-line
|
||||
manifest: require("../dll/dist/alpha-manifest.json") // eslint-disable-line
|
||||
}),
|
||||
new webpack.DllReferencePlugin({
|
||||
scope: "beta",
|
||||
manifest: require("../dll/js/beta-manifest.json"), // eslint-disable-line
|
||||
manifest: require("../dll/dist/beta-manifest.json"), // eslint-disable-line
|
||||
extensions: [".js", ".jsx"]
|
||||
})
|
||||
]
|
||||
|
|
|
|||
|
|
@ -20,23 +20,23 @@ module.exports = {
|
|||
beta: ["./beta", "./b", "./c"]
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "MyDll.[name].js",
|
||||
library: "[name]_[hash]"
|
||||
},
|
||||
plugins: [
|
||||
new webpack.DllPlugin({
|
||||
path: path.join(__dirname, "js", "[name]-manifest.json"),
|
||||
path: path.join(__dirname, "dist", "[name]-manifest.json"),
|
||||
name: "[name]_[hash]"
|
||||
})
|
||||
]
|
||||
};
|
||||
```
|
||||
|
||||
# js/MyDll.alpha.js
|
||||
# dist/MyDll.alpha.js
|
||||
|
||||
``` javascript
|
||||
var alpha_a716524c34bed97b283e =
|
||||
var alpha_100e8e712194d1301cec =
|
||||
```
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -105,7 +105,7 @@ var alpha_a716524c34bed97b283e =
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -164,10 +164,10 @@ module.exports = "module";
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/alpha-manifest.json
|
||||
# dist/alpha-manifest.json
|
||||
|
||||
``` javascript
|
||||
{"name":"alpha_a716524c34bed97b283e","content":{"./alpha.js":{"id":1,"buildMeta":{"providedExports":true}},"./a.js":{"id":2,"buildMeta":{"providedExports":true}},"../node_modules/module.js":{"id":3,"buildMeta":{"providedExports":true}}}}
|
||||
{"name":"alpha_100e8e712194d1301cec","content":{"./alpha.js":{"id":1,"buildMeta":{"providedExports":true}},"./a.js":{"id":2,"buildMeta":{"providedExports":true}},"../node_modules/module.js":{"id":3,"buildMeta":{"providedExports":true}}}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
@ -216,8 +216,8 @@ chunk {1} MyDll.beta.js (beta) 80 bytes [entry] [rendered]
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
MyDll.beta.js 689 bytes 0 [emitted] beta
|
||||
MyDll.alpha.js 698 bytes 1 [emitted] alpha
|
||||
MyDll.beta.js 691 bytes 0 [emitted] beta
|
||||
MyDll.alpha.js 700 bytes 1 [emitted] alpha
|
||||
Entrypoint alpha = MyDll.alpha.js
|
||||
Entrypoint beta = MyDll.beta.js
|
||||
chunk {0} MyDll.beta.js (beta) 80 bytes [entry] [rendered]
|
||||
|
|
|
|||
|
|
@ -11,16 +11,16 @@ This is the _reference_ bundle (with the manifests) for [dll user example](https
|
|||
{{webpack.config.js}}
|
||||
```
|
||||
|
||||
# js/MyDll.alpha.js
|
||||
# dist/MyDll.alpha.js
|
||||
|
||||
``` javascript
|
||||
{{js/MyDll.alpha.js}}
|
||||
{{dist/MyDll.alpha.js}}
|
||||
```
|
||||
|
||||
# js/alpha-manifest.json
|
||||
# dist/alpha-manifest.json
|
||||
|
||||
``` javascript
|
||||
{{js/alpha-manifest.json}}
|
||||
{{dist/alpha-manifest.json}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -10,13 +10,13 @@ module.exports = {
|
|||
beta: ["./beta", "./b", "./c"]
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "MyDll.[name].js",
|
||||
library: "[name]_[hash]"
|
||||
},
|
||||
plugins: [
|
||||
new webpack.DllPlugin({
|
||||
path: path.join(__dirname, "js", "[name]-manifest.json"),
|
||||
path: path.join(__dirname, "dist", "[name]-manifest.json"),
|
||||
name: "[name]_[hash]"
|
||||
})
|
||||
]
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ module.exports = [
|
|||
// mode: "development || "production",
|
||||
entry: ["./vendor", "./vendor2"],
|
||||
output: {
|
||||
path: path.resolve(__dirname, "js"),
|
||||
path: path.resolve(__dirname, "dist"),
|
||||
filename: "vendor.js",
|
||||
library: "vendor_[hash]"
|
||||
},
|
||||
|
|
@ -30,7 +30,7 @@ module.exports = [
|
|||
pageC: "./pageC"
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
@ -42,10 +42,10 @@ module.exports = [
|
|||
];
|
||||
```
|
||||
|
||||
# js/vendor.js
|
||||
# dist/vendor.js
|
||||
|
||||
``` javascript
|
||||
var vendor_29cbd7a62aad73543161 =
|
||||
var vendor_44a43fa9f51c57e4a162 =
|
||||
```
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -114,7 +114,7 @@ var vendor_29cbd7a62aad73543161 =
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -162,7 +162,7 @@ module.exports = "Vendor2";
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/pageA.js
|
||||
# dist/pageA.js
|
||||
|
||||
``` javascript
|
||||
/******/ (function(modules) { // webpackBootstrap
|
||||
|
|
@ -229,7 +229,7 @@ module.exports = "Vendor2";
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -249,22 +249,22 @@ module.exports = "pageA";
|
|||
/***/ }),
|
||||
/* 1 */
|
||||
/*!****************************************************************************!*\
|
||||
!*** delegated ./vendor.js from dll-reference vendor_29cbd7a62aad73543161 ***!
|
||||
!*** delegated ./vendor.js from dll-reference vendor_44a43fa9f51c57e4a162 ***!
|
||||
\****************************************************************************/
|
||||
/*! no static exports found */
|
||||
/***/ (function(module, exports, __webpack_require__) {
|
||||
|
||||
module.exports = (__webpack_require__(/*! dll-reference vendor_29cbd7a62aad73543161 */ 2))(1);
|
||||
module.exports = (__webpack_require__(/*! dll-reference vendor_44a43fa9f51c57e4a162 */ 2))(1);
|
||||
|
||||
/***/ }),
|
||||
/* 2 */
|
||||
/*!**********************************************!*\
|
||||
!*** external "vendor_29cbd7a62aad73543161" ***!
|
||||
!*** external "vendor_44a43fa9f51c57e4a162" ***!
|
||||
\**********************************************/
|
||||
/*! no static exports found */
|
||||
/***/ (function(module, exports) {
|
||||
|
||||
module.exports = vendor_29cbd7a62aad73543161;
|
||||
module.exports = vendor_44a43fa9f51c57e4a162;
|
||||
|
||||
/***/ })
|
||||
/******/ ]);
|
||||
|
|
@ -306,19 +306,19 @@ Child app:
|
|||
> pageA [0] ./pageA.js
|
||||
[0] ./pageA.js 60 bytes {0} [built]
|
||||
single entry ./pageA pageA
|
||||
[1] delegated ./vendor.js from dll-reference vendor_29cbd7a62aad73543161 42 bytes {0} [built]
|
||||
[1] delegated ./vendor.js from dll-reference vendor_44a43fa9f51c57e4a162 42 bytes {0} [built]
|
||||
cjs require ./vendor [0] ./pageA.js 1:12-31
|
||||
[2] external "vendor_29cbd7a62aad73543161" 42 bytes {0} {1} [built]
|
||||
delegated source dll-reference vendor_29cbd7a62aad73543161 [1] delegated ./vendor.js from dll-reference vendor_29cbd7a62aad73543161
|
||||
delegated source dll-reference vendor_29cbd7a62aad73543161 [4] delegated ./vendor2.js from dll-reference vendor_29cbd7a62aad73543161
|
||||
[2] external "vendor_44a43fa9f51c57e4a162" 42 bytes {0} {1} [built]
|
||||
delegated source dll-reference vendor_44a43fa9f51c57e4a162 [1] delegated ./vendor.js from dll-reference vendor_44a43fa9f51c57e4a162
|
||||
delegated source dll-reference vendor_44a43fa9f51c57e4a162 [4] delegated ./vendor2.js from dll-reference vendor_44a43fa9f51c57e4a162
|
||||
chunk {1} pageB.js (pageB) 145 bytes [entry] [rendered]
|
||||
> pageB [3] ./pageB.js
|
||||
[2] external "vendor_29cbd7a62aad73543161" 42 bytes {0} {1} [built]
|
||||
delegated source dll-reference vendor_29cbd7a62aad73543161 [1] delegated ./vendor.js from dll-reference vendor_29cbd7a62aad73543161
|
||||
delegated source dll-reference vendor_29cbd7a62aad73543161 [4] delegated ./vendor2.js from dll-reference vendor_29cbd7a62aad73543161
|
||||
[2] external "vendor_44a43fa9f51c57e4a162" 42 bytes {0} {1} [built]
|
||||
delegated source dll-reference vendor_44a43fa9f51c57e4a162 [1] delegated ./vendor.js from dll-reference vendor_44a43fa9f51c57e4a162
|
||||
delegated source dll-reference vendor_44a43fa9f51c57e4a162 [4] delegated ./vendor2.js from dll-reference vendor_44a43fa9f51c57e4a162
|
||||
[3] ./pageB.js 61 bytes {1} [built]
|
||||
single entry ./pageB pageB
|
||||
[4] delegated ./vendor2.js from dll-reference vendor_29cbd7a62aad73543161 42 bytes {1} [built]
|
||||
[4] delegated ./vendor2.js from dll-reference vendor_44a43fa9f51c57e4a162 42 bytes {1} [built]
|
||||
cjs require ./vendor2 [3] ./pageB.js 1:12-32
|
||||
chunk {2} pageC.js (pageC) 25 bytes [entry] [rendered]
|
||||
> pageC [5] ./pageC.js
|
||||
|
|
@ -334,7 +334,7 @@ Version: webpack next
|
|||
Child vendor:
|
||||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Asset Size Chunks Chunk Names
|
||||
vendor.js 668 bytes 0 [emitted] main
|
||||
vendor.js 670 bytes 0 [emitted] main
|
||||
Entrypoint main = vendor.js
|
||||
chunk {0} vendor.js (main) 65 bytes [entry] [rendered]
|
||||
> main [2] dll main
|
||||
|
|
@ -350,9 +350,9 @@ Child vendor:
|
|||
Child app:
|
||||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Asset Size Chunks Chunk Names
|
||||
pageC.js 566 bytes 0 [emitted] pageC
|
||||
pageB.js 674 bytes 1 [emitted] pageB
|
||||
pageA.js 676 bytes 2 [emitted] pageA
|
||||
pageC.js 568 bytes 0 [emitted] pageC
|
||||
pageB.js 676 bytes 1 [emitted] pageB
|
||||
pageA.js 678 bytes 2 [emitted] pageA
|
||||
Entrypoint pageA = pageA.js
|
||||
Entrypoint pageB = pageB.js
|
||||
Entrypoint pageC = pageC.js
|
||||
|
|
@ -362,19 +362,19 @@ Child app:
|
|||
single entry ./pageC pageC
|
||||
chunk {1} pageB.js (pageB) 145 bytes [entry] [rendered]
|
||||
> pageB [3] ./pageB.js
|
||||
[0] external "vendor_6b1d14c4fe9298d3969e" 42 bytes {1} {2} [built]
|
||||
delegated source dll-reference vendor_6b1d14c4fe9298d3969e [2] delegated ./vendor2.js from dll-reference vendor_6b1d14c4fe9298d3969e
|
||||
delegated source dll-reference vendor_6b1d14c4fe9298d3969e [4] delegated ./vendor.js from dll-reference vendor_6b1d14c4fe9298d3969e
|
||||
[2] delegated ./vendor2.js from dll-reference vendor_6b1d14c4fe9298d3969e 42 bytes {1} [built]
|
||||
[0] external "vendor_4931cea4c9b3fadeb2db" 42 bytes {1} {2} [built]
|
||||
delegated source dll-reference vendor_4931cea4c9b3fadeb2db [2] delegated ./vendor2.js from dll-reference vendor_4931cea4c9b3fadeb2db
|
||||
delegated source dll-reference vendor_4931cea4c9b3fadeb2db [4] delegated ./vendor.js from dll-reference vendor_4931cea4c9b3fadeb2db
|
||||
[2] delegated ./vendor2.js from dll-reference vendor_4931cea4c9b3fadeb2db 42 bytes {1} [built]
|
||||
cjs require ./vendor2 [3] ./pageB.js 1:12-32
|
||||
[3] ./pageB.js 61 bytes {1} [built]
|
||||
single entry ./pageB pageB
|
||||
chunk {2} pageA.js (pageA) 144 bytes [entry] [rendered]
|
||||
> pageA [5] ./pageA.js
|
||||
[0] external "vendor_6b1d14c4fe9298d3969e" 42 bytes {1} {2} [built]
|
||||
delegated source dll-reference vendor_6b1d14c4fe9298d3969e [2] delegated ./vendor2.js from dll-reference vendor_6b1d14c4fe9298d3969e
|
||||
delegated source dll-reference vendor_6b1d14c4fe9298d3969e [4] delegated ./vendor.js from dll-reference vendor_6b1d14c4fe9298d3969e
|
||||
[4] delegated ./vendor.js from dll-reference vendor_6b1d14c4fe9298d3969e 42 bytes {2} [built]
|
||||
[0] external "vendor_4931cea4c9b3fadeb2db" 42 bytes {1} {2} [built]
|
||||
delegated source dll-reference vendor_4931cea4c9b3fadeb2db [2] delegated ./vendor2.js from dll-reference vendor_4931cea4c9b3fadeb2db
|
||||
delegated source dll-reference vendor_4931cea4c9b3fadeb2db [4] delegated ./vendor.js from dll-reference vendor_4931cea4c9b3fadeb2db
|
||||
[4] delegated ./vendor.js from dll-reference vendor_4931cea4c9b3fadeb2db 42 bytes {2} [built]
|
||||
cjs require ./vendor [5] ./pageA.js 1:12-31
|
||||
[5] ./pageA.js 60 bytes {2} [built]
|
||||
single entry ./pageA pageA
|
||||
|
|
|
|||
|
|
@ -4,16 +4,16 @@
|
|||
{{webpack.config.js}}
|
||||
```
|
||||
|
||||
# js/vendor.js
|
||||
# dist/vendor.js
|
||||
|
||||
``` javascript
|
||||
{{js/vendor.js}}
|
||||
{{dist/vendor.js}}
|
||||
```
|
||||
|
||||
# js/pageA.js
|
||||
# dist/pageA.js
|
||||
|
||||
``` javascript
|
||||
{{js/pageA.js}}
|
||||
{{dist/pageA.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ module.exports = [
|
|||
// mode: "development || "production",
|
||||
entry: ["./vendor", "./vendor2"],
|
||||
output: {
|
||||
path: path.resolve(__dirname, "js"),
|
||||
path: path.resolve(__dirname, "dist"),
|
||||
filename: "vendor.js",
|
||||
library: "vendor_[hash]"
|
||||
},
|
||||
|
|
@ -27,7 +27,7 @@ module.exports = [
|
|||
pageC: "./pageC"
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ module.exports = {
|
|||
};
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
(function webpackUniversalModuleDefinition(root, factory) {
|
||||
|
|
@ -127,7 +127,7 @@ return /******/ (function(modules) { // webpackBootstrap
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
|
|||
|
|
@ -27,10 +27,10 @@ In the complex case we specify different values for each environment:
|
|||
{{webpack.config.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ module.exports = {
|
|||
};
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -207,7 +207,7 @@ module.exports = {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -334,7 +334,7 @@ Version: webpack next
|
|||
4.output.js 91 bytes 4 [emitted]
|
||||
5.output.js 91 bytes 5 [emitted]
|
||||
6.output.js 91 bytes 6 [emitted]
|
||||
output.js 2.01 KiB 7 [emitted] main
|
||||
output.js 2.02 KiB 7 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} 0.output.js (async2) 21 bytes {2} {7} [rendered]
|
||||
> async commons duplicate [2] ./example.js 1:0-52
|
||||
|
|
|
|||
|
|
@ -12,10 +12,10 @@
|
|||
{{webpack.config.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@ module.exports = {
|
|||
};
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -227,7 +227,7 @@ module.exports = {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -271,7 +271,7 @@ Promise.all(/*! require.ensure */[__webpack_require__.e(0), __webpack_require__.
|
|||
/******/ });
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[0],[
|
||||
|
|
@ -298,7 +298,7 @@ module.exports = "a";
|
|||
]]);
|
||||
```
|
||||
|
||||
# js/1.output.js
|
||||
# dist/1.output.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[1],{
|
||||
|
|
@ -317,7 +317,7 @@ module.exports = "d";
|
|||
}]);
|
||||
```
|
||||
|
||||
# js/2.output.js
|
||||
# dist/2.output.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[2],{
|
||||
|
|
|
|||
|
|
@ -44,28 +44,28 @@ Pretty useful for a router in a SPA.
|
|||
{{webpack.config.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/0.output.js}}
|
||||
{{dist/0.output.js}}
|
||||
```
|
||||
|
||||
# js/1.output.js
|
||||
# dist/1.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/1.output.js}}
|
||||
{{dist/1.output.js}}
|
||||
```
|
||||
|
||||
# js/2.output.js
|
||||
# dist/2.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/2.output.js}}
|
||||
{{dist/2.output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ export default "default";
|
|||
export var named = "named";
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -133,7 +133,7 @@ export var named = "named";
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -293,7 +293,7 @@ chunk {0} output.js (main) 1.17 KiB [entry] [rendered]
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
output.js 991 bytes 0 [emitted] main
|
||||
output.js 993 bytes 0 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} output.js (main) 1.17 KiB [entry] [rendered]
|
||||
> main [4] ./example.js
|
||||
|
|
|
|||
|
|
@ -29,10 +29,10 @@
|
|||
{{harmony.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ module.exports = {
|
|||
// mode: "development || "production",
|
||||
entry: "./example",
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "MyLibrary.umd.js",
|
||||
library: "MyLibrary",
|
||||
libraryTarget: "umd"
|
||||
|
|
@ -14,7 +14,7 @@ module.exports = {
|
|||
};
|
||||
```
|
||||
|
||||
# js/MyLibrary.umd.js
|
||||
# dist/MyLibrary.umd.js
|
||||
|
||||
``` javascript
|
||||
(function webpackUniversalModuleDefinition(root, factory) {
|
||||
|
|
@ -95,7 +95,7 @@ return /******/ (function(modules) { // webpackBootstrap
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -153,7 +153,7 @@ chunk {0} MyLibrary.umd.js (main) 97 bytes [entry] [rendered]
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
MyLibrary.umd.js 924 bytes 0 [emitted] main
|
||||
MyLibrary.umd.js 926 bytes 0 [emitted] main
|
||||
Entrypoint main = MyLibrary.umd.js
|
||||
chunk {0} MyLibrary.umd.js (main) 97 bytes [entry] [rendered]
|
||||
> main [0] ./example.js
|
||||
|
|
|
|||
|
|
@ -4,10 +4,10 @@
|
|||
{{webpack.config.js}}
|
||||
```
|
||||
|
||||
# js/MyLibrary.umd.js
|
||||
# dist/MyLibrary.umd.js
|
||||
|
||||
``` javascript
|
||||
{{js/MyLibrary.umd.js}}
|
||||
{{dist/MyLibrary.umd.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ module.exports = {
|
|||
// mode: "development || "production",
|
||||
entry: "./example",
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "MyLibrary.umd.js",
|
||||
library: "MyLibrary",
|
||||
libraryTarget: "umd"
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ export { a, b, c } from "./abc";
|
|||
export { add as reexportedAdd, multiply as reexportedMultiply } from "./math";
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -116,7 +116,7 @@ export { add as reexportedAdd, multiply as reexportedMultiply } from "./math";
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -227,10 +227,10 @@ function c() { console.log("c"); }
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
!function(t){function n(e){if(r[e])return r[e].exports;var u=r[e]={i:e,l:!1,exports:{}};return t[e].call(u.exports,u,u.exports,n),u.l=!0,u.exports}var r={};n.m=t,n.c=r,n.d=function(t,r,e){n.o(t,r)||Object.defineProperty(t,r,{configurable:!1,enumerable:!0,get:e})},n.r=function(t){Object.defineProperty(t,"__esModule",{value:!0})},n.n=function(t){var r=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(r,"a",r),r},n.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},n.p="js/",n(n.s=3)}([function(t,n,r){"use strict";function e(){for(var t=0,n=0,r=arguments,e=r.length;n<e;)t+=r[n++];return t}function u(){for(var t=1,n=0,r=arguments,e=r.length;n<e;)t*=r[n++];return t}r.d(n,"a",function(){return e}),r.d(n,"b",function(){return u})},function(t,n,r){"use strict"},function(t,n,r){"use strict";r(1);var e=r(0);r.d(n,"a",function(){return e.b})},function(t,n,r){"use strict";r.r(n);var e=r(0),u=r(2);Object(e.a)(1,2),u.a(1,2)}]);
|
||||
!function(t){function n(e){if(r[e])return r[e].exports;var u=r[e]={i:e,l:!1,exports:{}};return t[e].call(u.exports,u,u.exports,n),u.l=!0,u.exports}var r={};n.m=t,n.c=r,n.d=function(t,r,e){n.o(t,r)||Object.defineProperty(t,r,{configurable:!1,enumerable:!0,get:e})},n.r=function(t){Object.defineProperty(t,"__esModule",{value:!0})},n.n=function(t){var r=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(r,"a",r),r},n.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},n.p="dist/",n(n.s=3)}([function(t,n,r){"use strict";function e(){for(var t=0,n=0,r=arguments,e=r.length;n<e;)t+=r[n++];return t}function u(){for(var t=1,n=0,r=arguments,e=r.length;n<e;)t*=r[n++];return t}r.d(n,"a",function(){return e}),r.d(n,"b",function(){return u})},function(t,n,r){"use strict"},function(t,n,r){"use strict";r(1);var e=r(0);r.d(n,"a",function(){return e.b})},function(t,n,r){"use strict";r.r(n);var e=r(0),u=r(2);Object(e.a)(1,2),u.a(1,2)}]);
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
@ -241,7 +241,7 @@ function c() { console.log("c"); }
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
output.js 5.92 KiB 0 [emitted] main
|
||||
output.js 5.93 KiB 0 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} output.js (main) 726 bytes [entry] [rendered]
|
||||
> main [0] ./example.js
|
||||
|
|
@ -273,7 +273,7 @@ chunk {0} output.js (main) 726 bytes [entry] [rendered]
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
output.js 969 bytes 0 [emitted] main
|
||||
output.js 971 bytes 0 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} output.js (main) 726 bytes [entry] [rendered]
|
||||
> main [3] ./example.js
|
||||
|
|
|
|||
|
|
@ -24,16 +24,16 @@ In addition to that, `library.js` simulates an entry point to a big library. `li
|
|||
{{library.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{production:js/output.js}}
|
||||
{{production:dist/output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ export function increment(val) {
|
|||
};
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -180,7 +180,7 @@ export function increment(val) {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -301,7 +301,7 @@ Hash: 0a1b2c3d4e5f6a7b8c9d
|
|||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
0.output.js 144 bytes 0 [emitted]
|
||||
output.js 1.74 KiB 1 [emitted] main
|
||||
output.js 1.75 KiB 1 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} 0.output.js 25 bytes {1} [rendered]
|
||||
> [] 6:0-24
|
||||
|
|
|
|||
|
|
@ -11,10 +11,10 @@
|
|||
{{increment.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ module.exports = {
|
|||
cache: true, // better performance for the AggressiveSplittingPlugin
|
||||
entry: "./example",
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[chunkhash].js",
|
||||
chunkFilename: "[chunkhash].js"
|
||||
},
|
||||
|
|
@ -37,7 +37,7 @@ module.exports = {
|
|||
"process.env.NODE_ENV": JSON.stringify("production")
|
||||
})
|
||||
],
|
||||
recordsOutputPath: path.join(__dirname, "js", "records.json")
|
||||
recordsOutputPath: path.join(__dirname, "dist", "records.json")
|
||||
};
|
||||
```
|
||||
|
||||
|
|
@ -51,7 +51,7 @@ Version: webpack next
|
|||
Asset Size Chunks Chunk Names
|
||||
1d1f50c6f480a313a283.js 52.9 KiB 7 [emitted]
|
||||
650a1f5b6bbd5e2a0bcb.js 36.5 KiB 0 [emitted]
|
||||
85f47c3abb26198f77a8.js 60 KiB 2 [emitted]
|
||||
4a984680da6e56d39889.js 60 KiB 2 [emitted]
|
||||
de45e35c6080cc33435c.js 31.6 KiB 3 [emitted]
|
||||
b9d30d332886e3897e04.js 56.1 KiB 4 [emitted]
|
||||
091d7e57346e564d3d09.js 52.4 KiB 5 [emitted]
|
||||
|
|
@ -64,7 +64,7 @@ d12e724ddfa623596d6a.js 54.2 KiB 10 [emitted]
|
|||
0bb84ee671fc256e158e.js 51.2 KiB 12 [emitted]
|
||||
c8536008639de2173e51.js 58.2 KiB 13 [emitted]
|
||||
763fbc691b4fe33d506e.js 22 KiB 14 [emitted]
|
||||
Entrypoint main = 85f47c3abb26198f77a8.js de45e35c6080cc33435c.js 650a1f5b6bbd5e2a0bcb.js
|
||||
Entrypoint main = 4a984680da6e56d39889.js de45e35c6080cc33435c.js 650a1f5b6bbd5e2a0bcb.js
|
||||
chunk {0} 650a1f5b6bbd5e2a0bcb.js 32.4 KiB [initial] [rendered]
|
||||
> aggressive-splitted main [0] ./example.js
|
||||
[0] ./example.js 44 bytes {0} [built]
|
||||
|
|
@ -72,7 +72,7 @@ chunk {0} 650a1f5b6bbd5e2a0bcb.js 32.4 KiB [initial] [rendered]
|
|||
chunk {1} ad733bf1033fc5a7a830.js 31.4 KiB {0} {2} {3} [rendered] [recorded]
|
||||
> aggressive-splitted [0] ./example.js 2:0-22
|
||||
3 modules
|
||||
chunk {2} 85f47c3abb26198f77a8.js 48.8 KiB [entry] [rendered] [recorded]
|
||||
chunk {2} 4a984680da6e56d39889.js 48.8 KiB [entry] [rendered] [recorded]
|
||||
> aggressive-splitted main [0] ./example.js
|
||||
16 modules
|
||||
chunk {3} de45e35c6080cc33435c.js 30.5 KiB [initial] [rendered] [recorded]
|
||||
|
|
@ -132,9 +132,9 @@ cb73f4cb70c06c65b248.js 12.1 KiB 8 [emitted]
|
|||
53cef345d9ccd6bb3876.js 13 KiB 10 [emitted]
|
||||
c5b86ebb82485218af01.js 4.99 KiB 11 [emitted]
|
||||
0309b4e1ec5aa2f66403.js 7.02 KiB 12 [emitted]
|
||||
4e1c37d40514df5cc50e.js 10.2 KiB 13 [emitted]
|
||||
48e2dcb305baa66eaaff.js 10.2 KiB 13 [emitted]
|
||||
0b3c96677d32cb9cb074.js 5.91 KiB 14 [emitted]
|
||||
Entrypoint main = 4e1c37d40514df5cc50e.js 0309b4e1ec5aa2f66403.js 0b3c96677d32cb9cb074.js
|
||||
Entrypoint main = 48e2dcb305baa66eaaff.js 0309b4e1ec5aa2f66403.js 0b3c96677d32cb9cb074.js
|
||||
chunk {0} ae85856cebfcdd8c297c.js 18.9 KiB {12} {13} {14} [rendered]
|
||||
> aggressive-splitted [30] ./example.js 2:0-22
|
||||
9 modules
|
||||
|
|
@ -174,7 +174,7 @@ chunk {11} c5b86ebb82485218af01.js 31.4 KiB {12} {13} {14} [rendered] [recorde
|
|||
chunk {12} 0309b4e1ec5aa2f66403.js 30.5 KiB [initial] [rendered] [recorded]
|
||||
> aggressive-splitted main [30] ./example.js
|
||||
3 modules
|
||||
chunk {13} 4e1c37d40514df5cc50e.js 48.8 KiB [entry] [rendered] [recorded]
|
||||
chunk {13} 48e2dcb305baa66eaaff.js 48.8 KiB [entry] [rendered] [recorded]
|
||||
> aggressive-splitted main [30] ./example.js
|
||||
16 modules
|
||||
chunk {14} 0b3c96677d32cb9cb074.js 32.4 KiB [initial] [rendered]
|
||||
|
|
@ -596,7 +596,7 @@ chunk {14} 0b3c96677d32cb9cb074.js 32.4 KiB [initial] [rendered]
|
|||
"../../node_modules/react/lib/ReactVersion.js",
|
||||
"../../node_modules/create-react-class/factory.js"
|
||||
],
|
||||
"hash": "85f47c3abb26198f77a84b0d186d3d6f",
|
||||
"hash": "4a984680da6e56d398893f0087df99fd",
|
||||
"id": 2
|
||||
},
|
||||
{
|
||||
|
|
|
|||
|
|
@ -37,5 +37,5 @@ The backward compatibility (non HTTP2 client) improves with bigger `maxSize`, as
|
|||
## Records
|
||||
|
||||
```
|
||||
{{js/records.json}}
|
||||
{{dist/records.json}}
|
||||
```
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ module.exports = {
|
|||
cache: true, // better performance for the AggressiveSplittingPlugin
|
||||
entry: "./example",
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[chunkhash].js",
|
||||
chunkFilename: "[chunkhash].js"
|
||||
},
|
||||
|
|
@ -18,5 +18,5 @@ module.exports = {
|
|||
"process.env.NODE_ENV": JSON.stringify("production")
|
||||
})
|
||||
],
|
||||
recordsOutputPath: path.join(__dirname, "js", "records.json")
|
||||
recordsOutputPath: path.join(__dirname, "dist", "records.json")
|
||||
};
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ module.exports = {
|
|||
"commons": "./router"
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
publicPath: "js/",
|
||||
filename: "[name].bundle.js",
|
||||
chunkFilename: "[id].chunk.js"
|
||||
|
|
@ -95,7 +95,7 @@ window.onLinkToPage = function onLinkToPage(name) { // name is "a" or "b"
|
|||
</html>
|
||||
```
|
||||
|
||||
# js/commons.js
|
||||
# dist/commons.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -268,7 +268,7 @@ window.onLinkToPage = function onLinkToPage(name) { // name is "a" or "b"
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -421,7 +421,7 @@ window.onLinkToPage = function onLinkToPage(name) { // name is "a" or "b"
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/pageA.bundle.js
|
||||
# dist/pageA.bundle.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[3],{
|
||||
|
|
@ -455,7 +455,7 @@ render(__webpack_require__(/*! ./aPage */ 2));
|
|||
},[[8,4,3]]]);
|
||||
```
|
||||
|
||||
# js/1.chunk.js
|
||||
# dist/1.chunk.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[1],[
|
||||
|
|
|
|||
|
|
@ -32,22 +32,22 @@
|
|||
{{pageA.html}}
|
||||
```
|
||||
|
||||
# js/commons.js
|
||||
# dist/commons.js
|
||||
|
||||
``` javascript
|
||||
{{js/commons.js}}
|
||||
{{dist/commons.js}}
|
||||
```
|
||||
|
||||
# js/pageA.bundle.js
|
||||
# dist/pageA.bundle.js
|
||||
|
||||
``` javascript
|
||||
{{js/pageA.bundle.js}}
|
||||
{{dist/pageA.bundle.js}}
|
||||
```
|
||||
|
||||
# js/1.chunk.js
|
||||
# dist/1.chunk.js
|
||||
|
||||
``` javascript
|
||||
{{js/1.chunk.js}}
|
||||
{{dist/1.chunk.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ module.exports = {
|
|||
"commons": "./router"
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
publicPath: "js/",
|
||||
filename: "[name].bundle.js",
|
||||
chunkFilename: "[id].chunk.js"
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ module.exports = Object.keys(languages).map(function(language) {
|
|||
// mode: "development || "production",
|
||||
entry: "./example",
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: language + ".output.js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
@ -47,7 +47,7 @@ module.exports = Object.keys(languages).map(function(language) {
|
|||
}
|
||||
```
|
||||
|
||||
# js/de.output.js
|
||||
# dist/de.output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -116,7 +116,7 @@ module.exports = Object.keys(languages).map(function(language) {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -142,7 +142,7 @@ console.log("Missing Text");
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/en.output.js
|
||||
# dist/en.output.js
|
||||
|
||||
``` javascript
|
||||
/******/ (function(modules) { // webpackBootstrap
|
||||
|
|
@ -209,7 +209,7 @@ console.log("Missing Text");
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -268,7 +268,7 @@ Version: webpack next
|
|||
Child en:
|
||||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Asset Size Chunks Chunk Names
|
||||
en.output.js 604 bytes 0 [emitted] main
|
||||
en.output.js 606 bytes 0 [emitted] main
|
||||
Entrypoint main = en.output.js
|
||||
chunk {0} en.output.js (main) 65 bytes [entry] [rendered]
|
||||
> main [0] ./example.js
|
||||
|
|
@ -277,7 +277,7 @@ Child en:
|
|||
Child de:
|
||||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Asset Size Chunks Chunk Names
|
||||
de.output.js 603 bytes 0 [emitted] main
|
||||
de.output.js 605 bytes 0 [emitted] main
|
||||
Entrypoint main = de.output.js
|
||||
chunk {0} de.output.js (main) 65 bytes [entry] [rendered]
|
||||
> main [0] ./example.js
|
||||
|
|
|
|||
|
|
@ -23,16 +23,16 @@ The I18nPlugin replaces every occurrence of the i18n function `__(...)` with a c
|
|||
{{de.json}}
|
||||
```
|
||||
|
||||
# js/de.output.js
|
||||
# dist/de.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/de.output.js}}
|
||||
{{dist/de.output.js}}
|
||||
```
|
||||
|
||||
# js/en.output.js
|
||||
# dist/en.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/en.output.js}}
|
||||
{{dist/en.output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ module.exports = Object.keys(languages).map(function(language) {
|
|||
// mode: "development || "production",
|
||||
entry: "./example",
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: language + ".output.js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ module.exports = function(content) {
|
|||
}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -100,7 +100,7 @@ module.exports = function(content) {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
|
|||
|
|
@ -22,10 +22,10 @@
|
|||
{{test.css}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# Console output
|
||||
|
|
|
|||
|
|
@ -54,7 +54,7 @@ require(
|
|||
);
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -213,7 +213,7 @@ require(
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -315,7 +315,7 @@ __webpack_require__.e(/*! AMD require */ 0).then(function() { var __WEBPACK_AMD_
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[0],[
|
||||
|
|
@ -407,7 +407,7 @@ Hash: 0a1b2c3d4e5f6a7b8c9d
|
|||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
0.output.js 1.87 KiB 0 [emitted]
|
||||
output.js 9.72 KiB 1 [emitted] main
|
||||
output.js 9.73 KiB 1 [emitted] main
|
||||
Entrypoint main = output.js
|
||||
chunk {0} 0.output.js 439 bytes {1} [rendered]
|
||||
> [3] ./example.js 7:0-14:1
|
||||
|
|
|
|||
|
|
@ -20,16 +20,16 @@ You see that everything is working nicely together.
|
|||
{{commonjs.js}}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/0.output.js}}
|
||||
{{dist/0.output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ require(["./a", "./b", "./c", "./d"]);
|
|||
var path = require("path");
|
||||
var CommonsChunkPlugin = require("../../lib/optimize/CommonsChunkPlugin");
|
||||
var outputOptions = {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].bundle.js",
|
||||
chunkFilename: "[id].chunk.js"
|
||||
};
|
||||
|
|
@ -200,7 +200,7 @@ Child pageC:
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Asset Size Chunks Chunk Names
|
||||
0.chunk.js 247 bytes 0 [emitted]
|
||||
pageC.bundle.js 7.98 KiB 1 [emitted] pageC
|
||||
pageC.bundle.js 7.99 KiB 1 [emitted] pageC
|
||||
Entrypoint pageC = pageC.bundle.js
|
||||
chunk {0} 0.chunk.js 21 bytes {1} [rendered]
|
||||
> duplicate [4] ./page.js 2:0-23
|
||||
|
|
@ -297,7 +297,7 @@ Child pageC:
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Asset Size Chunks Chunk Names
|
||||
0.chunk.js 90 bytes 0 [emitted]
|
||||
pageC.bundle.js 1.86 KiB 1 [emitted] pageC
|
||||
pageC.bundle.js 1.87 KiB 1 [emitted] pageC
|
||||
Entrypoint pageC = pageC.bundle.js
|
||||
chunk {0} 0.chunk.js 21 bytes {1} [rendered]
|
||||
> duplicate [4] ./page.js 2:0-23
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
var path = require("path");
|
||||
var CommonsChunkPlugin = require("../../lib/optimize/CommonsChunkPlugin");
|
||||
var outputOptions = {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].bundle.js",
|
||||
chunkFilename: "[id].chunk.js"
|
||||
};
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ module.exports = [
|
|||
// mode: "development || "production",
|
||||
entry: "./example",
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "mobile.js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
@ -33,7 +33,7 @@ module.exports = [
|
|||
// mode: "development || "production",
|
||||
entry: "./example",
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "desktop.js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
@ -45,7 +45,7 @@ module.exports = [
|
|||
];
|
||||
```
|
||||
|
||||
# js/desktop.js
|
||||
# dist/desktop.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -114,7 +114,7 @@ module.exports = [
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -142,7 +142,7 @@ console.log("Running " + "desktop" + " build");
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/mobile.js
|
||||
# dist/mobile.js
|
||||
|
||||
``` javascript
|
||||
/******/ (function(modules) { // webpackBootstrap
|
||||
|
|
@ -209,7 +209,7 @@ console.log("Running " + "desktop" + " build");
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -279,7 +279,7 @@ Version: webpack next
|
|||
Child mobile:
|
||||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Asset Size Chunks Chunk Names
|
||||
mobile.js 606 bytes 0 [emitted] main
|
||||
mobile.js 608 bytes 0 [emitted] main
|
||||
Entrypoint main = mobile.js
|
||||
chunk {0} mobile.js (main) 117 bytes [entry] [rendered]
|
||||
> main [1] ./example.js
|
||||
|
|
@ -290,7 +290,7 @@ Child mobile:
|
|||
Child desktop:
|
||||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Asset Size Chunks Chunk Names
|
||||
desktop.js 586 bytes 0 [emitted] main
|
||||
desktop.js 588 bytes 0 [emitted] main
|
||||
Entrypoint main = desktop.js
|
||||
chunk {0} desktop.js (main) 97 bytes [entry] [rendered]
|
||||
> main [0] ./example.js
|
||||
|
|
|
|||
|
|
@ -11,16 +11,16 @@
|
|||
{{webpack.config.js}}
|
||||
```
|
||||
|
||||
# js/desktop.js
|
||||
# dist/desktop.js
|
||||
|
||||
``` javascript
|
||||
{{js/desktop.js}}
|
||||
{{dist/desktop.js}}
|
||||
```
|
||||
|
||||
# js/mobile.js
|
||||
# dist/mobile.js
|
||||
|
||||
``` javascript
|
||||
{{js/mobile.js}}
|
||||
{{dist/mobile.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ module.exports = [
|
|||
// mode: "development || "production",
|
||||
entry: "./example",
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "mobile.js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
@ -20,7 +20,7 @@ module.exports = [
|
|||
// mode: "development || "production",
|
||||
entry: "./example",
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "desktop.js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ module.exports = {
|
|||
beta: "./beta"
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "MyLibrary.[name].js",
|
||||
library: ["MyLibrary", "[name]"],
|
||||
libraryTarget: "umd"
|
||||
|
|
@ -31,7 +31,7 @@ module.exports = {
|
|||
};
|
||||
```
|
||||
|
||||
# js/MyLibrary.alpha.js
|
||||
# dist/MyLibrary.alpha.js
|
||||
|
||||
``` javascript
|
||||
(function webpackUniversalModuleDefinition(root, factory) {
|
||||
|
|
@ -112,7 +112,7 @@ return /******/ (function(modules) { // webpackBootstrap
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
@ -138,7 +138,7 @@ module.exports = "alpha";
|
|||
});
|
||||
```
|
||||
|
||||
# js/MyLibrary.beta.js
|
||||
# dist/MyLibrary.beta.js
|
||||
|
||||
``` javascript
|
||||
(function webpackUniversalModuleDefinition(root, factory) {
|
||||
|
|
@ -215,7 +215,7 @@ return /******/ (function(modules) { // webpackBootstrap
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 1);
|
||||
|
|
@ -265,8 +265,8 @@ chunk {1} MyLibrary.beta.js (beta) 24 bytes [entry] [rendered]
|
|||
Hash: 0a1b2c3d4e5f6a7b8c9d
|
||||
Version: webpack next
|
||||
Asset Size Chunks Chunk Names
|
||||
MyLibrary.beta.js 826 bytes 0 [emitted] beta
|
||||
MyLibrary.alpha.js 830 bytes 1 [emitted] alpha
|
||||
MyLibrary.beta.js 828 bytes 0 [emitted] beta
|
||||
MyLibrary.alpha.js 832 bytes 1 [emitted] alpha
|
||||
Entrypoint alpha = MyLibrary.alpha.js
|
||||
Entrypoint beta = MyLibrary.beta.js
|
||||
chunk {0} MyLibrary.beta.js (beta) 24 bytes [entry] [rendered]
|
||||
|
|
|
|||
|
|
@ -18,16 +18,16 @@ Note: When your library has dependencies that should not be included in the comp
|
|||
{{webpack.config.js}}
|
||||
```
|
||||
|
||||
# js/MyLibrary.alpha.js
|
||||
# dist/MyLibrary.alpha.js
|
||||
|
||||
``` javascript
|
||||
{{js/MyLibrary.alpha.js}}
|
||||
{{dist/MyLibrary.alpha.js}}
|
||||
```
|
||||
|
||||
# js/MyLibrary.beta.js
|
||||
# dist/MyLibrary.beta.js
|
||||
|
||||
``` javascript
|
||||
{{js/MyLibrary.beta.js}}
|
||||
{{dist/MyLibrary.beta.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ module.exports = {
|
|||
beta: "./beta"
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "MyLibrary.[name].js",
|
||||
library: ["MyLibrary", "[name]"],
|
||||
libraryTarget: "umd"
|
||||
|
|
|
|||
|
|
@ -29,7 +29,7 @@ module.exports = {
|
|||
adminPageC: "./adminPageC",
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
@ -75,7 +75,7 @@ module.exports = {
|
|||
</html>
|
||||
```
|
||||
|
||||
# js/commons.js
|
||||
# dist/commons.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -248,7 +248,7 @@ module.exports = {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -290,7 +290,7 @@ module.exports = {
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/pageA.js
|
||||
# dist/pageA.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[0],[
|
||||
|
|
@ -322,7 +322,7 @@ __webpack_require__(/*! ./modules/a-c */ 3);
|
|||
],[[0,7,0]]]);
|
||||
```
|
||||
|
||||
# js/admin-commons.js
|
||||
# dist/admin-commons.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[6],{
|
||||
|
|
@ -341,7 +341,7 @@ __webpack_require__(/*! ./modules/a-c */ 3);
|
|||
}]);
|
||||
```
|
||||
|
||||
# js/adminPageA.js
|
||||
# dist/adminPageA.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[3],{
|
||||
|
|
|
|||
|
|
@ -28,28 +28,28 @@
|
|||
{{adminPageA.html}}
|
||||
```
|
||||
|
||||
# js/commons.js
|
||||
# dist/commons.js
|
||||
|
||||
``` javascript
|
||||
{{js/commons.js}}
|
||||
{{dist/commons.js}}
|
||||
```
|
||||
|
||||
# js/pageA.js
|
||||
# dist/pageA.js
|
||||
|
||||
``` javascript
|
||||
{{js/pageA.js}}
|
||||
{{dist/pageA.js}}
|
||||
```
|
||||
|
||||
# js/admin-commons.js
|
||||
# dist/admin-commons.js
|
||||
|
||||
``` javascript
|
||||
{{js/admin-commons.js}}
|
||||
{{dist/admin-commons.js}}
|
||||
```
|
||||
|
||||
# js/adminPageA.js
|
||||
# dist/adminPageA.js
|
||||
|
||||
``` javascript
|
||||
{{js/adminPageA.js}}
|
||||
{{dist/adminPageA.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ module.exports = {
|
|||
adminPageC: "./adminPageC",
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].js"
|
||||
},
|
||||
plugins: [
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ module.exports = {
|
|||
C: "./c",
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].js"
|
||||
},
|
||||
module: {
|
||||
|
|
@ -99,7 +99,7 @@ module.exports = {
|
|||
};
|
||||
```
|
||||
|
||||
# js/A.js
|
||||
# dist/A.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[0],{
|
||||
|
|
@ -131,57 +131,57 @@ __webpack_require__(/*! ./styleA.css */ 7);
|
|||
},[[0,3,0]]]);
|
||||
```
|
||||
|
||||
# js/commons.css
|
||||
# dist/commons.css
|
||||
|
||||
``` css
|
||||
body {
|
||||
background: url(js/ce21cbdd9b894e6af794813eb3fdaf60.png);
|
||||
background: url(dist/ce21cbdd9b894e6af794813eb3fdaf60.png);
|
||||
}
|
||||
```
|
||||
|
||||
# js/A.css
|
||||
# dist/A.css
|
||||
|
||||
``` css
|
||||
.a {
|
||||
background: url(js/d090b6fba0f6d326d282a19146ff54a7.png);
|
||||
background: url(dist/d090b6fba0f6d326d282a19146ff54a7.png);
|
||||
}
|
||||
```
|
||||
|
||||
# js/B.css
|
||||
# dist/B.css
|
||||
|
||||
``` css
|
||||
.b {
|
||||
background: url(js/16155c689e517682064c99893cb832cc.png);
|
||||
background: url(dist/16155c689e517682064c99893cb832cc.png);
|
||||
}
|
||||
```
|
||||
|
||||
# js/B.css (Minimized)
|
||||
# dist/B.css (Minimized)
|
||||
|
||||
``` css
|
||||
.b {
|
||||
background: url(js/16155c689e517682064c99893cb832cc.png);
|
||||
background: url(dist/16155c689e517682064c99893cb832cc.png);
|
||||
}
|
||||
```
|
||||
|
||||
# js/C.css
|
||||
# dist/C.css
|
||||
|
||||
``` css
|
||||
body {
|
||||
background: url(js/ce21cbdd9b894e6af794813eb3fdaf60.png);
|
||||
background: url(dist/ce21cbdd9b894e6af794813eb3fdaf60.png);
|
||||
}
|
||||
.c {
|
||||
background: url(js/c2a2f62d69330b7d787782f5010f9d13.png);
|
||||
background: url(dist/c2a2f62d69330b7d787782f5010f9d13.png);
|
||||
}
|
||||
```
|
||||
|
||||
# js/C.css (Minimized)
|
||||
# dist/C.css (Minimized)
|
||||
|
||||
``` css
|
||||
body {
|
||||
background: url(js/ce21cbdd9b894e6af794813eb3fdaf60.png);
|
||||
background: url(dist/ce21cbdd9b894e6af794813eb3fdaf60.png);
|
||||
}
|
||||
.c {
|
||||
background: url(js/c2a2f62d69330b7d787782f5010f9d13.png);
|
||||
background: url(dist/c2a2f62d69330b7d787782f5010f9d13.png);
|
||||
}
|
||||
```
|
||||
|
||||
|
|
@ -201,10 +201,10 @@ c2a2f62d69330b7d787782f5010f9d13.png 120 bytes [emitted]
|
|||
B.js 551 bytes 1 [emitted] B
|
||||
16155c689e517682064c99893cb832cc.png 120 bytes [emitted]
|
||||
commons.js 7.26 KiB 3 [emitted] commons
|
||||
A.css 69 bytes 0 [emitted] A
|
||||
B.css 69 bytes 1 [emitted] B
|
||||
C.css 140 bytes 2 [emitted] C
|
||||
commons.css 71 bytes 3 [emitted] commons
|
||||
A.css 71 bytes 0 [emitted] A
|
||||
B.css 71 bytes 1 [emitted] B
|
||||
C.css 144 bytes 2 [emitted] C
|
||||
commons.css 73 bytes 3 [emitted] commons
|
||||
Entrypoint A = commons.js commons.css A.js A.css
|
||||
Entrypoint B = commons.js commons.css B.js B.css
|
||||
Entrypoint C = C.js C.css
|
||||
|
|
@ -284,11 +284,11 @@ c2a2f62d69330b7d787782f5010f9d13.png 120 bytes [emitted]
|
|||
B.js 118 bytes 0 [emitted] B
|
||||
A.js 120 bytes 1 [emitted] A
|
||||
16155c689e517682064c99893cb832cc.png 120 bytes [emitted]
|
||||
C.js 574 bytes 3 [emitted] C
|
||||
A.css 69 bytes 1 [emitted] A
|
||||
B.css 69 bytes 0 [emitted] B
|
||||
C.css 140 bytes 3 [emitted] C
|
||||
commons.css 71 bytes 2 [emitted] commons
|
||||
C.js 576 bytes 3 [emitted] C
|
||||
A.css 71 bytes 1 [emitted] A
|
||||
B.css 71 bytes 0 [emitted] B
|
||||
C.css 144 bytes 3 [emitted] C
|
||||
commons.css 73 bytes 2 [emitted] commons
|
||||
Entrypoint A = commons.js commons.css A.js A.css
|
||||
Entrypoint B = commons.js commons.css B.js B.css
|
||||
Entrypoint C = C.js C.css
|
||||
|
|
|
|||
|
|
@ -47,46 +47,46 @@
|
|||
{{webpack.config.js}}
|
||||
```
|
||||
|
||||
# js/A.js
|
||||
# dist/A.js
|
||||
|
||||
``` javascript
|
||||
{{js/A.js}}
|
||||
{{dist/A.js}}
|
||||
```
|
||||
|
||||
# js/commons.css
|
||||
# dist/commons.css
|
||||
|
||||
``` css
|
||||
{{js/commons.css}}
|
||||
{{dist/commons.css}}
|
||||
```
|
||||
|
||||
# js/A.css
|
||||
# dist/A.css
|
||||
|
||||
``` css
|
||||
{{js/A.css}}
|
||||
{{dist/A.css}}
|
||||
```
|
||||
|
||||
# js/B.css
|
||||
# dist/B.css
|
||||
|
||||
``` css
|
||||
{{js/B.css}}
|
||||
{{dist/B.css}}
|
||||
```
|
||||
|
||||
# js/B.css (Minimized)
|
||||
# dist/B.css (Minimized)
|
||||
|
||||
``` css
|
||||
{{production:js/B.css}}
|
||||
{{production:dist/B.css}}
|
||||
```
|
||||
|
||||
# js/C.css
|
||||
# dist/C.css
|
||||
|
||||
``` css
|
||||
{{js/C.css}}
|
||||
{{dist/C.css}}
|
||||
```
|
||||
|
||||
# js/C.css (Minimized)
|
||||
# dist/C.css (Minimized)
|
||||
|
||||
``` css
|
||||
{{production:js/C.css}}
|
||||
{{production:dist/C.css}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ module.exports = {
|
|||
C: "./c",
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].js"
|
||||
},
|
||||
module: {
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ module.exports = {
|
|||
pageB: "./pageB"
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].bundle.js",
|
||||
chunkFilename: "[id].chunk.js"
|
||||
},
|
||||
|
|
@ -85,7 +85,7 @@ module.exports = {
|
|||
</html>
|
||||
```
|
||||
|
||||
# js/commons.js
|
||||
# dist/commons.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -258,7 +258,7 @@ module.exports = {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -290,7 +290,7 @@ module.exports = "Common";
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/pageA.bundle.js
|
||||
# dist/pageA.bundle.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[2],{
|
||||
|
|
@ -312,7 +312,7 @@ __webpack_require__.e(/*! AMD require | duplicate */ 0).then(function() { var __
|
|||
},[[3,3,2]]]);
|
||||
```
|
||||
|
||||
# js/pageB.bundle.js
|
||||
# dist/pageB.bundle.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[1],{
|
||||
|
|
@ -335,7 +335,7 @@ __webpack_require__.e(/*! require.ensure | duplicate */ 0).then((function(requir
|
|||
},[[2,3,1]]]);
|
||||
```
|
||||
|
||||
# js/0.chunk.js
|
||||
# dist/0.chunk.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[0],[
|
||||
|
|
@ -400,7 +400,7 @@ Version: webpack next
|
|||
0.chunk.js 120 bytes 0 [emitted]
|
||||
pageB.bundle.js 168 bytes 1 [emitted] pageB
|
||||
pageA.bundle.js 193 bytes 2 [emitted] pageA
|
||||
commons.js 1.74 KiB 3 [emitted] commons
|
||||
commons.js 1.75 KiB 3 [emitted] commons
|
||||
Entrypoint pageA = commons.js pageA.bundle.js
|
||||
Entrypoint pageB = commons.js pageB.bundle.js
|
||||
chunk {0} 0.chunk.js 91 bytes {1} {2} [rendered]
|
||||
|
|
|
|||
|
|
@ -50,28 +50,28 @@ You can also see the info that is printed to console. It shows among others:
|
|||
{{pageA.html}}
|
||||
```
|
||||
|
||||
# js/commons.js
|
||||
# dist/commons.js
|
||||
|
||||
``` javascript
|
||||
{{js/commons.js}}
|
||||
{{dist/commons.js}}
|
||||
```
|
||||
|
||||
# js/pageA.bundle.js
|
||||
# dist/pageA.bundle.js
|
||||
|
||||
``` javascript
|
||||
{{js/pageA.bundle.js}}
|
||||
{{dist/pageA.bundle.js}}
|
||||
```
|
||||
|
||||
# js/pageB.bundle.js
|
||||
# dist/pageB.bundle.js
|
||||
|
||||
``` javascript
|
||||
{{js/pageB.bundle.js}}
|
||||
{{dist/pageB.bundle.js}}
|
||||
```
|
||||
|
||||
# js/0.chunk.js
|
||||
# dist/0.chunk.js
|
||||
|
||||
``` javascript
|
||||
{{js/0.chunk.js}}
|
||||
{{dist/0.chunk.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ module.exports = {
|
|||
pageB: "./pageB"
|
||||
},
|
||||
output: {
|
||||
path: path.join(__dirname, "js"),
|
||||
path: path.join(__dirname, "dist"),
|
||||
filename: "[name].bundle.js",
|
||||
chunkFilename: "[id].chunk.js"
|
||||
},
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ require.ensure(["b"], function(require) {
|
|||
```
|
||||
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -183,7 +183,7 @@ require.ensure(["b"], function(require) {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // on error function for async loading
|
||||
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
||||
|
|
@ -249,7 +249,7 @@ __webpack_require__.e(/*! require.ensure */ 1).then((function(require) {
|
|||
/******/ ]);
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[0],[
|
||||
|
|
@ -288,7 +288,7 @@ __webpack_require__.e(/*! require.ensure */ 1).then((function(require) {
|
|||
]]);
|
||||
```
|
||||
|
||||
# js/1.output.js
|
||||
# dist/1.output.js
|
||||
|
||||
``` javascript
|
||||
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[1],[
|
||||
|
|
|
|||
|
|
@ -5,22 +5,22 @@
|
|||
```
|
||||
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
``` javascript
|
||||
{{js/output.js}}
|
||||
{{dist/output.js}}
|
||||
```
|
||||
|
||||
# js/0.output.js
|
||||
# dist/0.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/0.output.js}}
|
||||
{{dist/0.output.js}}
|
||||
```
|
||||
|
||||
# js/1.output.js
|
||||
# dist/1.output.js
|
||||
|
||||
``` javascript
|
||||
{{js/1.output.js}}
|
||||
{{dist/1.output.js}}
|
||||
```
|
||||
|
||||
# Info
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ module.exports = function() {
|
|||
}
|
||||
```
|
||||
|
||||
# js/output.js
|
||||
# dist/output.js
|
||||
|
||||
<details><summary><code>/******/ (function(modules) { /* webpackBootstrap */ })</code></summary>
|
||||
|
||||
|
|
@ -91,7 +91,7 @@ module.exports = function() {
|
|||
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||||
/******/
|
||||
/******/ // __webpack_public_path__
|
||||
/******/ __webpack_require__.p = "js/";
|
||||
/******/ __webpack_require__.p = "dist/";
|
||||
/******/
|
||||
/******/ // Load entry module and return exports
|
||||
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue