Skip to content

Commit

Permalink
fix: remove bundler info (#29)
Browse files Browse the repository at this point in the history
  • Loading branch information
fi3ework authored Jul 9, 2024
1 parent 5f38246 commit ec80e4d
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 79 deletions.
80 changes: 1 addition & 79 deletions e2e/cases/alias/__snapshots__/index.test.ts.snap
Original file line number Diff line number Diff line change
@@ -1,46 +1,7 @@
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html

exports[`alias should work 1`] = `
"var __webpack_modules__ = ({});
/************************************************************************/
// The module cache
var __webpack_module_cache__ = {};
// The require function
function __webpack_require__(moduleId) {
// Check if module is in cache
var cachedModule = __webpack_module_cache__[moduleId];
if (cachedModule !== undefined) {
return cachedModule.exports;
}
// Create a new module (and put it into the cache)
var module = (__webpack_module_cache__[moduleId] = {
exports: {}
});
// Execute the module function
__webpack_modules__[moduleId](module, module.exports, __webpack_require__);
// Return the exports of the module
return module.exports;
}
/************************************************************************/
// webpack/runtime/rspack_version
(() => {
__webpack_require__.rv = function () {
return "1.0.0-canary-0b368b6-20240704171208";
};
})();
// webpack/runtime/rspack_unique_id
(() => {
__webpack_require__.ruid = "[email protected]";
})();
/************************************************************************/
var __webpack_exports__ = {};
"var __webpack_exports__ = {};
;// CONCATENATED MODULE: ./e2e/cases/alias/src/a.ts
const a = 'hello world';
Expand All @@ -56,45 +17,6 @@ export { a };
exports[`alias should work 2`] = `
"(() => { // webpackBootstrap
"use strict";
var __webpack_modules__ = ({});
/************************************************************************/
// The module cache
var __webpack_module_cache__ = {};
// The require function
function __webpack_require__(moduleId) {
// Check if module is in cache
var cachedModule = __webpack_module_cache__[moduleId];
if (cachedModule !== undefined) {
return cachedModule.exports;
}
// Create a new module (and put it into the cache)
var module = (__webpack_module_cache__[moduleId] = {
exports: {}
});
// Execute the module function
__webpack_modules__[moduleId](module, module.exports, __webpack_require__);
// Return the exports of the module
return module.exports;
}
/************************************************************************/
// webpack/runtime/rspack_version
(() => {
__webpack_require__.rv = function () {
return "1.0.0-canary-0b368b6-20240704171208";
};
})();
// webpack/runtime/rspack_unique_id
(() => {
__webpack_require__.ruid = "[email protected]";
})();
/************************************************************************/
var __webpack_exports__ = {};
;// CONCATENATED MODULE: ./e2e/cases/alias/src/a.ts
Expand Down
9 changes: 9 additions & 0 deletions packages/core/src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,15 @@ export async function createInternalRsbuildConfig(): Promise<RsbuildConfig> {
},
tools: {
htmlPlugin: false,
rspack: {
experiments: {
rspackFuture: {
bundlerInfo: {
force: false,
},
},
},
},
},
output: {
filenameHash: false,
Expand Down
19 changes: 19 additions & 0 deletions packages/core/tests/__snapshots__/config.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,13 @@ exports[`Should compose create Rsbuild config correctly > Merge Rsbuild config 1
"tools": {
"htmlPlugin": false,
"rspack": {
"experiments": {
"rspackFuture": {
"bundlerInfo": {
"force": false,
},
},
},
"externalsType": "commonjs",
"output": {
"library": {
Expand Down Expand Up @@ -65,6 +72,11 @@ exports[`Should compose create Rsbuild config correctly > Merge Rsbuild config 1
"rspack": {
"experiments": {
"outputModule": true,
"rspackFuture": {
"bundlerInfo": {
"force": false,
},
},
},
"externalsType": "module",
"optimization": {
Expand Down Expand Up @@ -104,6 +116,13 @@ exports[`Should compose create Rsbuild config correctly > Merge Rsbuild config 1
"tools": {
"htmlPlugin": false,
"rspack": {
"experiments": {
"rspackFuture": {
"bundlerInfo": {
"force": false,
},
},
},
"externalsType": "umd",
"output": {
"library": {
Expand Down
4 changes: 4 additions & 0 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit ec80e4d

Please sign in to comment.