Skip to content

Commit 6d5dbd3

Browse files
authored
chore: remove divider comment from output (#12109)
1 parent c891a13 commit 6d5dbd3

File tree

25 files changed

+13
-57
lines changed

25 files changed

+13
-57
lines changed

crates/rspack_plugin_javascript/src/plugin/mod.rs

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -646,27 +646,18 @@ impl JsPlugin {
646646
sources.add(RawStringSource::from_static("var __webpack_modules__ = ("));
647647
sources.add(chunk_modules_source);
648648
sources.add(RawStringSource::from_static(");\n"));
649-
sources.add(RawStringSource::from(
650-
"/************************************************************************/\n",
651-
));
652649
}
653650
if !header.is_empty() {
654651
let mut header = header.join("\n");
655652
header.push('\n');
656653
sources.add(RawStringSource::from(header));
657-
sources.add(RawStringSource::from(
658-
"/************************************************************************/\n",
659-
));
660654
}
661655

662656
if compilation
663657
.chunk_graph
664658
.has_chunk_runtime_modules(chunk_ukey)
665659
{
666660
sources.add(render_runtime_modules(compilation, chunk_ukey).await?);
667-
sources.add(RawStringSource::from(
668-
"/************************************************************************/\n",
669-
));
670661
}
671662
if let Some(inlined_modules) = inlined_modules {
672663
let last_entry_module = inlined_modules
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
```html title=output.html
2-
<!doctype html><html><head><meta charset="UTF-8"><title>Rspack App</title><script crossorigin integrity="sha512-cSJqM1iOYI0DWuIXBCzg4Xn3yicy3OXtMHRaGmY+WjQcmvsTEPWkCb/u3BjfoYV7dkiIIOHX5NzL8SCuSG0F1A==" src="/runtime.js"></script><script crossorigin integrity="sha512-ageTNzTjw37fYTfNXstZKSaeoabDd0GR9bvijtEoQGGdaV4S7SpMpCErRGS/3V9Ih6FGobenWCtSBzh22uuL4g==" src="/index.js"></script><link crossorigin href="/index.css" integrity="sha512-vjhejkvTX8D8jzzC5Lc9ToCtcEDb0/NqtYmEHOid+ycq64hvW+JTG7Dw/ACFP6rApgiYwVMbEt6Zfb8j4EoZTA==" rel="stylesheet"></head><body></body></html>
2+
<!doctype html><html><head><meta charset="UTF-8"><title>Rspack App</title><script crossorigin integrity="sha512-4KS0VpDHV6JuPhsZD3JhllWg/4KuYM4rk2EopXa5vVrYLhUZAHBElDiv6XwaGfM66F+S5HdMsYNW4ietmMH/yA==" src="/runtime.js"></script><script crossorigin integrity="sha512-ageTNzTjw37fYTfNXstZKSaeoabDd0GR9bvijtEoQGGdaV4S7SpMpCErRGS/3V9Ih6FGobenWCtSBzh22uuL4g==" src="/index.js"></script><link crossorigin href="/index.css" integrity="sha512-vjhejkvTX8D8jzzC5Lc9ToCtcEDb0/NqtYmEHOid+ycq64hvW+JTG7Dw/ACFP6rApgiYwVMbEt6Zfb8j4EoZTA==" rel="stylesheet"></head><body></body></html>
33
```

tests/rspack-test/configCases/library/modern-module-force-concaten/__snapshot__/b.js.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ module.exports = 'b'
55
}),
66

77
});
8-
/************************************************************************/
98
// The module cache
109
var __webpack_module_cache__ = {};
1110

@@ -29,7 +28,6 @@ return module.exports;
2928

3029
}
3130

32-
/************************************************************************/
3331
// startup
3432
// Load entry module and return exports
3533
// This entry module is referenced by other modules so it can't be inlined

tests/rspack-test/configCases/library/modern-module-force-concaten/__snapshot__/e.js.txt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ module.exports = 'bar'
55
}),
66

77
});
8-
/************************************************************************/
98
// The module cache
109
var __webpack_module_cache__ = {};
1110

@@ -29,7 +28,6 @@ return module.exports;
2928

3029
}
3130

32-
/************************************************************************/
3331
// webpack/runtime/compat_get_default_export
3432
(() => {
3533
// getDefaultExport function for compatibility with non-ESM modules
@@ -56,7 +54,6 @@ __webpack_require__.d = (exports, definition) => {
5654
(() => {
5755
__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
5856
})();
59-
/************************************************************************/
6057

6158
// EXTERNAL MODULE: ./e/bar.cjs
6259
var bar = __webpack_require__(100);

tests/rspack-test/configCases/library/modern-module-force-concaten/__snapshot__/f.js.txt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ module.exports = path.sep
1414
}),
1515

1616
});
17-
/************************************************************************/
1817
// The module cache
1918
var __webpack_module_cache__ = {};
2019

@@ -38,7 +37,6 @@ return module.exports;
3837

3938
}
4039

41-
/************************************************************************/
4240
// webpack/runtime/compat_get_default_export
4341
(() => {
4442
// getDefaultExport function for compatibility with non-ESM modules
@@ -65,7 +63,6 @@ __webpack_require__.d = (exports, definition) => {
6563
(() => {
6664
__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
6765
})();
68-
/************************************************************************/
6966

7067
// EXTERNAL MODULE: ./f/bar.cjs
7168
var bar = __webpack_require__(227);

tests/rspack-test/configCases/library/modern-module-force-concaten/__snapshot__/g.js.txt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ module.exports = 'foo'
66
}),
77

88
});
9-
/************************************************************************/
109
// The module cache
1110
var __webpack_module_cache__ = {};
1211

@@ -30,7 +29,6 @@ return module.exports;
3029

3130
}
3231

33-
/************************************************************************/
3432
// webpack/runtime/compat_get_default_export
3533
(() => {
3634
// getDefaultExport function for compatibility with non-ESM modules
@@ -57,7 +55,6 @@ __webpack_require__.d = (exports, definition) => {
5755
(() => {
5856
__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
5957
})();
60-
/************************************************************************/
6158

6259
// EXTERNAL MODULE: ./g/foo.js
6360
var foo = __webpack_require__(547);

tests/rspack-test/configCases/library/render-order-issue/__snapshots__/entry.mjs.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,6 @@ __WEBPACK_EXTERNAL_MODULE_externals1__.v;
5656
}),
5757

5858
});
59-
/************************************************************************/
6059
// The module cache
6160
var __webpack_module_cache__ = {};
6261

@@ -80,7 +79,6 @@ return module.exports;
8079

8180
}
8281

83-
/************************************************************************/
8482
// startup
8583
// Load entry module and return exports
8684
// This entry module used 'module' so it can't be inlined

tests/rspack-test/configCases/rsdoctor/assets/rspack.config.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,11 +37,11 @@ module.exports = {
3737
Array [
3838
Object {
3939
path: a.js,
40-
size: 4229,
40+
size: 4004,
4141
},
4242
Object {
4343
path: b.js,
44-
size: 4229,
44+
size: 4004,
4545
},
4646
Object {
4747
path: c_js.js,

tests/rspack-test/hookCases/compilation#afterProcessAssets/basic/output.snap.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ module.exports = "This is hook"
88
}),
99

1010
});
11-
/************************************************************************/
1211
// The module cache
1312
var __webpack_module_cache__ = {};
1413

@@ -32,7 +31,6 @@ return module.exports;
3231

3332
}
3433

35-
/************************************************************************/
3634
// startup
3735
// Load entry module and return exports
3836
// This entry module is referenced by other modules so it can't be inlined

tests/rspack-test/hookCases/compilation#chunkHash/update-hash/output.snap.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ module.exports = "This is hook"
88
}),
99

1010
});
11-
/************************************************************************/
1211
// The module cache
1312
var __webpack_module_cache__ = {};
1413

@@ -32,7 +31,6 @@ return module.exports;
3231

3332
}
3433

35-
/************************************************************************/
3634
// startup
3735
// Load entry module and return exports
3836
// This entry module is referenced by other modules so it can't be inlined

0 commit comments

Comments
 (0)