rollup 2.66.1 → 2.67.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +28 -1
- package/dist/bin/rollup +9 -9
- package/dist/es/rollup.browser.js +3 -3
- package/dist/es/rollup.js +2 -2
- package/dist/es/shared/rollup.js +8329 -8341
- package/dist/es/shared/watch.js +17 -17
- package/dist/loadConfigFile.js +2 -2
- package/dist/rollup.browser.js +3 -3
- package/dist/rollup.browser.js.map +1 -1
- package/dist/rollup.d.ts +2 -3
- package/dist/rollup.js +2 -2
- package/dist/shared/index.js +17 -17
- package/dist/shared/loadConfigFile.js +4 -4
- package/dist/shared/mergeOptions.js +2 -2
- package/dist/shared/rollup.js +89 -101
- package/dist/shared/watch-cli.js +15 -15
- package/dist/shared/watch.js +2 -2
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,32 @@
|
|
|
1
1
|
# rollup changelog
|
|
2
2
|
|
|
3
|
+
## 2.67.0
|
|
4
|
+
|
|
5
|
+
_2022-02-02_
|
|
6
|
+
|
|
7
|
+
### Features
|
|
8
|
+
|
|
9
|
+
- Improve side effect detection when using Array.prototype.groupBy/groupByToMap (#4360)
|
|
10
|
+
- Allow changing `moduleSideEffects` at any time during the build (#4379)
|
|
11
|
+
- Soft-deprecate `ModuleInfo.hasModuleSideEffects` in favour of `ModuleInfo.moduleSideEffects` (#4379)
|
|
12
|
+
|
|
13
|
+
### Bug Fixes
|
|
14
|
+
|
|
15
|
+
- Do not include queries and hashes in generated file names when preserving modules (#4374)
|
|
16
|
+
|
|
17
|
+
### Pull Requests
|
|
18
|
+
|
|
19
|
+
- [#4319](https://github.com/rollup/rollup/pull/4319): refactor: use fs, fs-extra, remove sander (@dnalborczyk)
|
|
20
|
+
- [#4360](https://github.com/rollup/rollup/pull/4360): feat: add Array.prototype.groupBy/groupByToMap (@dnalborczyk)
|
|
21
|
+
- [#4361](https://github.com/rollup/rollup/pull/4361): fix: more types (@dnalborczyk)
|
|
22
|
+
- [#4369](https://github.com/rollup/rollup/pull/4369): fix: remove acorn-walk patch (@dnalborczyk)
|
|
23
|
+
- [#4371](https://github.com/rollup/rollup/pull/4371): refactor: use fs.promises in cli/run (@dnalborczyk)
|
|
24
|
+
- [#4372](https://github.com/rollup/rollup/pull/4372): refactor: use fs.promises in module loader (@dnalborczyk)
|
|
25
|
+
- [#4374](https://github.com/rollup/rollup/pull/4374): Ignore queries and hashes in file names when preserving modules (@lukastaegert)
|
|
26
|
+
- [#4375](https://github.com/rollup/rollup/pull/4375): Fix typo in \_config.js (@eltociear)
|
|
27
|
+
- [#4376](https://github.com/rollup/rollup/pull/4376): refactor: fs.promises, move mkdir to writeoutputfile, Part 3 (@dnalborczyk)
|
|
28
|
+
- [#4379](https://github.com/rollup/rollup/pull/4379): Deprecate hasModuleSideEffects in favor of moduleSideEffects and ensure it is mutable on ModuleInfo (@lukastaegert)
|
|
29
|
+
|
|
3
30
|
## 2.66.1
|
|
4
31
|
|
|
5
32
|
_2022-01-25_
|
|
@@ -11,7 +38,7 @@ _2022-01-25_
|
|
|
11
38
|
|
|
12
39
|
### Pull Requests
|
|
13
40
|
|
|
14
|
-
- [#4362](https://github.com/rollup/rollup/pull/4362): refactor: convert exportsByName object to map (@
|
|
41
|
+
- [#4362](https://github.com/rollup/rollup/pull/4362): refactor: convert exportsByName object to map (@dnalborczyk)
|
|
15
42
|
- [#4363](https://github.com/rollup/rollup/pull/4363): Do not warn unnecessarily for namespace conflicts (@lukastaegert)
|
|
16
43
|
- [#4364](https://github.com/rollup/rollup/pull/4364): Do not expose synthetic namespace export in entries and namespaces (@lukastaegert)
|
|
17
44
|
|
package/dist/bin/rollup
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
/*
|
|
4
4
|
@license
|
|
5
|
-
Rollup.js v2.
|
|
6
|
-
|
|
5
|
+
Rollup.js v2.67.0
|
|
6
|
+
Wed, 02 Feb 2022 06:19:08 GMT - commit 61d772ba59be605e53e72613ae51cee4b72aee64
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
https://github.com/rollup/rollup
|
|
@@ -16,7 +16,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
16
16
|
|
|
17
17
|
const rollup = require('../shared/rollup.js');
|
|
18
18
|
const require$$2 = require('util');
|
|
19
|
-
const
|
|
19
|
+
const require$$0$1 = require('fs');
|
|
20
20
|
const require$$0 = require('path');
|
|
21
21
|
const mergeOptions = require('../shared/mergeOptions.js');
|
|
22
22
|
const loadConfigFile_js = require('../shared/loadConfigFile.js');
|
|
@@ -1217,7 +1217,7 @@ const parser = new YargsParser({
|
|
|
1217
1217
|
return require(path);
|
|
1218
1218
|
}
|
|
1219
1219
|
else if (path.match(/\.json$/)) {
|
|
1220
|
-
return
|
|
1220
|
+
return require$$0$1.readFileSync(path, 'utf8');
|
|
1221
1221
|
}
|
|
1222
1222
|
else {
|
|
1223
1223
|
throw Error('only .json config files are supported in ESM');
|
|
@@ -1569,9 +1569,9 @@ async function build(inputOptions, warnings, silent = false) {
|
|
|
1569
1569
|
}
|
|
1570
1570
|
|
|
1571
1571
|
const DEFAULT_CONFIG_BASE = 'rollup.config';
|
|
1572
|
-
function getConfigPath(commandConfig) {
|
|
1572
|
+
async function getConfigPath(commandConfig) {
|
|
1573
1573
|
if (commandConfig === true) {
|
|
1574
|
-
return require$$0.resolve(findConfigFileNameInCwd());
|
|
1574
|
+
return require$$0.resolve(await findConfigFileNameInCwd());
|
|
1575
1575
|
}
|
|
1576
1576
|
if (commandConfig.slice(0, 5) === 'node:') {
|
|
1577
1577
|
const pkgName = commandConfig.slice(5);
|
|
@@ -1595,8 +1595,8 @@ function getConfigPath(commandConfig) {
|
|
|
1595
1595
|
}
|
|
1596
1596
|
return require$$0.resolve(commandConfig);
|
|
1597
1597
|
}
|
|
1598
|
-
function findConfigFileNameInCwd() {
|
|
1599
|
-
const filesInWorkingDir = new Set(
|
|
1598
|
+
async function findConfigFileNameInCwd() {
|
|
1599
|
+
const filesInWorkingDir = new Set(await require$$0$1.promises.readdir(process$1.cwd()));
|
|
1600
1600
|
for (const extension of ['mjs', 'cjs', 'ts']) {
|
|
1601
1601
|
const fileName = `${DEFAULT_CONFIG_BASE}.${extension}`;
|
|
1602
1602
|
if (filesInWorkingDir.has(fileName))
|
|
@@ -1696,7 +1696,7 @@ async function runRollup(command) {
|
|
|
1696
1696
|
}
|
|
1697
1697
|
async function getConfigs(command) {
|
|
1698
1698
|
if (command.config) {
|
|
1699
|
-
const configFile = getConfigPath(command.config);
|
|
1699
|
+
const configFile = await getConfigPath(command.config);
|
|
1700
1700
|
const { options, warnings } = await loadConfigFile_js.loadAndParseConfigFile(configFile, command);
|
|
1701
1701
|
return { options, warnings };
|
|
1702
1702
|
}
|