Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

rollup

Package Overview
Dependencies
Maintainers
5
Versions
836
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rollup - npm Package Compare versions

Comparing version 4.4.1 to 4.9.4

4

dist/es/getLogFilter.js
/*
@license
Rollup.js v4.4.1
Tue, 14 Nov 2023 05:24:21 GMT - commit 01d8c9d1b68919c2c429427ae7e60f503a8bb5f4
Rollup.js v4.9.4
Sat, 06 Jan 2024 06:38:31 GMT - commit 18372035f167ec104280e1e91ef795e4f7033f1e

@@ -6,0 +6,0 @@ https://github.com/rollup/rollup

/*
@license
Rollup.js v4.4.1
Tue, 14 Nov 2023 05:24:21 GMT - commit 01d8c9d1b68919c2c429427ae7e60f503a8bb5f4
Rollup.js v4.9.4
Sat, 06 Jan 2024 06:38:31 GMT - commit 18372035f167ec104280e1e91ef795e4f7033f1e

@@ -6,0 +6,0 @@ https://github.com/rollup/rollup

/*
@license
Rollup.js v4.4.1
Tue, 14 Nov 2023 05:24:21 GMT - commit 01d8c9d1b68919c2c429427ae7e60f503a8bb5f4
Rollup.js v4.9.4
Sat, 06 Jan 2024 06:38:31 GMT - commit 18372035f167ec104280e1e91ef795e4f7033f1e

@@ -6,0 +6,0 @@ https://github.com/rollup/rollup

/*
@license
Rollup.js v4.4.1
Tue, 14 Nov 2023 05:24:21 GMT - commit 01d8c9d1b68919c2c429427ae7e60f503a8bb5f4
Rollup.js v4.9.4
Sat, 06 Jan 2024 06:38:31 GMT - commit 18372035f167ec104280e1e91ef795e4f7033f1e

@@ -6,0 +6,0 @@ https://github.com/rollup/rollup

/*
@license
Rollup.js v4.4.1
Tue, 14 Nov 2023 05:24:21 GMT - commit 01d8c9d1b68919c2c429427ae7e60f503a8bb5f4
Rollup.js v4.9.4
Sat, 06 Jan 2024 06:38:31 GMT - commit 18372035f167ec104280e1e91ef795e4f7033f1e

@@ -6,0 +6,0 @@ https://github.com/rollup/rollup

@@ -17,4 +17,5 @@ const { existsSync } = require('node:fs');

linux: {
arm: { base: 'linux-arm-gnueabihf' },
arm: { base: 'linux-arm-gnueabihf', musl: null },
arm64: { base: 'linux-arm64-gnu', musl: 'linux-arm64-musl' },
riscv64: { base: 'linux-riscv64-gnu', musl: null },
x64: { base: 'linux-x64-gnu', musl: 'linux-x64-musl' }

@@ -29,4 +30,11 @@ },

const imported = bindingsByPlatformAndArch[platform]?.[arch];
if (!imported) {
const msvcLinkFilenameByArch = {
arm64: 'vc_redist.arm64.exe',
ia32: 'vc_redist.x86.exe',
x64: 'vc_redist.x64.exe'
};
const packageBase = getPackageBase();
if (!packageBase) {
throw new Error(

@@ -49,5 +57,44 @@ `Your current platform "${platform}" and architecture "${arch}" combination is not yet supported by the native Rollup build. Please use the WASM build "@rollup/wasm-node" instead.

const packageBase = imported.musl && isMusl() ? imported.musl : imported.base;
function getPackageBase() {
const imported = bindingsByPlatformAndArch[platform]?.[arch];
if (!imported) {
return null;
}
if ('musl' in imported && isMusl()) {
return imported.musl;
}
return imported.base;
}
const localName = `./rollup.${packageBase}.node`;
const { parse, parseAsync, xxhashBase64Url } = require(
const requireWithFriendlyError = id => {
try {
return require(id);
} catch (error) {
if (
platform === 'win32' &&
error instanceof Error &&
error.code === 'ERR_DLOPEN_FAILED' &&
error.message.includes('The specified module could not be found')
) {
const msvcDownloadLink = `https://aka.ms/vs/17/release/${msvcLinkFilenameByArch[arch]}`;
throw new Error(
`Failed to load module ${id}. ` +
'Required DLL was not found. ' +
'This error usually happens when Microsoft Visual C++ Redistributable is not installed. ' +
`You can download it from ${msvcDownloadLink}`,
{ cause: error }
);
}
throw new Error(
`Cannot find module ${id}. ` +
`npm has a bug related to optional dependencies (https://github.com/npm/cli/issues/4828). ` +
'Please try `npm i` again after removing both package-lock.json and node_modules directory.',
{ cause: error }
);
}
};
const { parse, parseAsync, xxhashBase64Url } = requireWithFriendlyError(
existsSync(join(__dirname, localName)) ? localName : `@rollup/rollup-${packageBase}`

@@ -54,0 +101,0 @@ );

/*
@license
Rollup.js v4.4.1
Tue, 14 Nov 2023 05:24:21 GMT - commit 01d8c9d1b68919c2c429427ae7e60f503a8bb5f4
Rollup.js v4.9.4
Sat, 06 Jan 2024 06:38:31 GMT - commit 18372035f167ec104280e1e91ef795e4f7033f1e

@@ -6,0 +6,0 @@ https://github.com/rollup/rollup

@@ -0,1 +1,3 @@

import type { Program } from 'estree';
export const VERSION: string;

@@ -101,3 +103,3 @@

export interface SourceDescription extends Partial<PartialNull<ModuleOptions>> {
ast?: AstNode;
ast?: ProgramNode;
code: string;

@@ -108,3 +110,3 @@ map?: SourceMapInput;

export interface TransformModuleJSON {
ast?: AstNode;
ast?: ProgramNode;
code: string;

@@ -120,3 +122,3 @@ // note if plugins use new this.cache to opt-out auto transform cache

export interface ModuleJSON extends TransformModuleJSON, ModuleOptions {
ast: AstNode;
ast: ProgramNode;
dependencies: string[];

@@ -177,3 +179,3 @@ id: string;

interface ModuleInfo extends ModuleOptions {
ast: AstNode | null;
ast: ProgramNode | null;
code: string | null;

@@ -211,3 +213,3 @@ dynamicImporters: readonly string[];

options?: { allowReturnOutsideFunction?: boolean }
) => AstNode;
) => ProgramNode;

@@ -222,3 +224,3 @@ // declare AbortSignal here for environments without DOM lib or @types/node

options?: { allowReturnOutsideFunction?: boolean; signal?: AbortSignal }
) => Promise<AstNode>;
) => Promise<ProgramNode>;

@@ -289,3 +291,3 @@ export interface PluginContext extends MinimalPluginContext {

options: {
ast: AstNode;
ast: ProgramNode;
code: string;

@@ -987,2 +989,4 @@ id: string;

type ProgramNode = Program & AstNode;
export function defineConfig(options: RollupOptions): RollupOptions;

@@ -989,0 +993,0 @@ export function defineConfig(options: RollupOptions[]): RollupOptions[];

/*
@license
Rollup.js v4.4.1
Tue, 14 Nov 2023 05:24:21 GMT - commit 01d8c9d1b68919c2c429427ae7e60f503a8bb5f4
Rollup.js v4.9.4
Sat, 06 Jan 2024 06:38:31 GMT - commit 18372035f167ec104280e1e91ef795e4f7033f1e

@@ -15,14 +15,82 @@ https://github.com/rollup/rollup

const rollup = require('./shared/rollup.js');
const watchProxy = require('./shared/watch-proxy.js');
require('./shared/parseAst.js');
require('./native.js');
require('node:path');
const parseAst_js = require('./shared/parseAst.js');
const fseventsImporter = require('./shared/fsevents-importer.js');
require('node:process');
require('tty');
require('node:path');
require('path');
require('node:perf_hooks');
require('./native.js');
require('node:fs/promises');
require('./shared/fsevents-importer.js');
class WatchEmitter {
constructor() {
this.currentHandlers = Object.create(null);
this.persistentHandlers = Object.create(null);
}
// Will be overwritten by Rollup
async close() { }
emit(event, ...parameters) {
return Promise.all([...this.getCurrentHandlers(event), ...this.getPersistentHandlers(event)].map(handler => handler(...parameters)));
}
off(event, listener) {
const listeners = this.persistentHandlers[event];
if (listeners) {
// A hack stolen from "mitt": ">>> 0" does not change numbers >= 0, but -1
// (which would remove the last array element if used unchanged) is turned
// into max_int, which is outside the array and does not change anything.
listeners.splice(listeners.indexOf(listener) >>> 0, 1);
}
return this;
}
on(event, listener) {
this.getPersistentHandlers(event).push(listener);
return this;
}
onCurrentRun(event, listener) {
this.getCurrentHandlers(event).push(listener);
return this;
}
once(event, listener) {
const selfRemovingListener = (...parameters) => {
this.off(event, selfRemovingListener);
return listener(...parameters);
};
this.on(event, selfRemovingListener);
return this;
}
removeAllListeners() {
this.removeListenersForCurrentRun();
this.persistentHandlers = Object.create(null);
return this;
}
removeListenersForCurrentRun() {
this.currentHandlers = Object.create(null);
return this;
}
getCurrentHandlers(event) {
return this.currentHandlers[event] || (this.currentHandlers[event] = []);
}
getPersistentHandlers(event) {
return this.persistentHandlers[event] || (this.persistentHandlers[event] = []);
}
}
function watch(configs) {
const emitter = new WatchEmitter();
watchInternal(configs, emitter).catch(error => {
rollup.handleError(error);
});
return emitter;
}
async function watchInternal(configs, emitter) {
const optionsList = await Promise.all(rollup.ensureArray(configs).map(config => rollup.mergeOptions(config, true)));
const watchOptionsList = optionsList.filter(config => config.watch !== false);
if (watchOptionsList.length === 0) {
return parseAst_js.error(parseAst_js.logInvalidOption('watch', parseAst_js.URL_WATCH, 'there must be at least one config where "watch" is not set to "false"'));
}
await fseventsImporter.loadFsEvents();
const { Watcher } = await Promise.resolve().then(() => require('./shared/watch.js'));
new Watcher(watchOptionsList, emitter);
}

@@ -32,3 +100,3 @@ exports.VERSION = rollup.version;

exports.rollup = rollup.rollup;
exports.watch = watchProxy.watch;
exports.watch = watch;
//# sourceMappingURL=rollup.js.map
/*
@license
Rollup.js v4.4.1
Tue, 14 Nov 2023 05:24:21 GMT - commit 01d8c9d1b68919c2c429427ae7e60f503a8bb5f4
Rollup.js v4.9.4
Sat, 06 Jan 2024 06:38:31 GMT - commit 18372035f167ec104280e1e91ef795e4f7033f1e

@@ -6,0 +6,0 @@ https://github.com/rollup/rollup

/*
@license
Rollup.js v4.4.1
Tue, 14 Nov 2023 05:24:21 GMT - commit 01d8c9d1b68919c2c429427ae7e60f503a8bb5f4
Rollup.js v4.9.4
Sat, 06 Jan 2024 06:38:31 GMT - commit 18372035f167ec104280e1e91ef795e4f7033f1e

@@ -6,0 +6,0 @@ https://github.com/rollup/rollup

/*
@license
Rollup.js v4.4.1
Tue, 14 Nov 2023 05:24:21 GMT - commit 01d8c9d1b68919c2c429427ae7e60f503a8bb5f4
Rollup.js v4.9.4
Sat, 06 Jan 2024 06:38:31 GMT - commit 18372035f167ec104280e1e91ef795e4f7033f1e

@@ -22,3 +22,3 @@ https://github.com/rollup/rollup

const node_child_process = require('node:child_process');
const watchProxy = require('./watch-proxy.js');
const rollup_js = require('../rollup.js');
require('fs');

@@ -489,3 +489,3 @@ require('util');

async function start(configs, warnings) {
watcher = watchProxy.watch(configs);
watcher = rollup_js.watch(configs);
watcher.on('event', event => {

@@ -492,0 +492,0 @@ switch (event.code) {

/*
@license
Rollup.js v4.4.1
Tue, 14 Nov 2023 05:24:21 GMT - commit 01d8c9d1b68919c2c429427ae7e60f503a8bb5f4
Rollup.js v4.9.4
Sat, 06 Jan 2024 06:38:31 GMT - commit 18372035f167ec104280e1e91ef795e4f7033f1e

@@ -90,3 +90,3 @@ https://github.com/rollup/rollup

create: 'buggy',
delete: null,
delete: null, //delete file from map
update: 'create'

@@ -257,3 +257,9 @@ },

this.updateWatchedFiles(result);
this.skipWrite || (await Promise.all(this.outputs.map(output => result.write(output))));
if (!this.skipWrite) {
await Promise.all(this.outputs.map(output => result.write(output)));
if (this.closed) {
return;
}
this.updateWatchedFiles(result);
}
await this.watcher.emitter.emit('event', {

@@ -260,0 +266,0 @@ code: 'BUNDLE_END',

@@ -53,2 +53,24 @@ # Rollup core license

> The MIT License (MIT)
>
> Copyright (c) 2019 RollupJS Plugin Contributors (https://github.com/rollup/plugins/graphs/contributors)
>
> Permission is hereby granted, free of charge, to any person obtaining a copy
> of this software and associated documentation files (the "Software"), to deal
> in the Software without restriction, including without limitation the rights
> to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
> copies of the Software, and to permit persons to whom the Software is
> furnished to do so, subject to the following conditions:
>
> The above copyright notice and this permission notice shall be included in
> all copies or substantial portions of the Software.
>
> THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
> IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
> FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
> AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
> LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
> OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
> THE SOFTWARE.
---------------------------------------

@@ -55,0 +77,0 @@

{
"name": "rollup",
"version": "4.4.1",
"version": "4.9.4",
"description": "Next-generation ES module bundler",

@@ -27,2 +27,3 @@ "main": "dist/rollup.js",

"i686-pc-windows-msvc",
"riscv64gc-unknown-linux-gnu",
"x86_64-apple-darwin",

@@ -84,3 +85,3 @@ "x86_64-pc-windows-msvc",

"test:only": "mocha test/test.js",
"test:typescript": "shx rm -rf test/typescript/dist && shx cp -r dist test/typescript/ && tsc --noEmit -p test/typescript && tsc --noEmit",
"test:typescript": "shx rm -rf test/typescript/dist && shx cp -r dist test/typescript/ && tsc --noEmit -p test/typescript && tsc --noEmit && tsc --noEmit -p scripts",
"test:browser": "mocha test/browser/index.js",

@@ -105,15 +106,19 @@ "watch": "rollup --config rollup.config.ts --configPlugin typescript --watch"

"fsevents": "~2.3.2",
"@rollup/rollup-darwin-arm64": "4.4.1",
"@rollup/rollup-android-arm64": "4.4.1",
"@rollup/rollup-win32-arm64-msvc": "4.4.1",
"@rollup/rollup-linux-arm64-gnu": "4.4.1",
"@rollup/rollup-linux-arm64-musl": "4.4.1",
"@rollup/rollup-android-arm-eabi": "4.4.1",
"@rollup/rollup-linux-arm-gnueabihf": "4.4.1",
"@rollup/rollup-win32-ia32-msvc": "4.4.1",
"@rollup/rollup-darwin-x64": "4.4.1",
"@rollup/rollup-win32-x64-msvc": "4.4.1",
"@rollup/rollup-linux-x64-gnu": "4.4.1",
"@rollup/rollup-linux-x64-musl": "4.4.1"
"@rollup/rollup-darwin-arm64": "4.9.4",
"@rollup/rollup-android-arm64": "4.9.4",
"@rollup/rollup-win32-arm64-msvc": "4.9.4",
"@rollup/rollup-linux-arm64-gnu": "4.9.4",
"@rollup/rollup-linux-arm64-musl": "4.9.4",
"@rollup/rollup-android-arm-eabi": "4.9.4",
"@rollup/rollup-linux-arm-gnueabihf": "4.9.4",
"@rollup/rollup-win32-ia32-msvc": "4.9.4",
"@rollup/rollup-linux-riscv64-gnu": "4.9.4",
"@rollup/rollup-darwin-x64": "4.9.4",
"@rollup/rollup-win32-x64-msvc": "4.9.4",
"@rollup/rollup-linux-x64-gnu": "4.9.4",
"@rollup/rollup-linux-x64-musl": "4.9.4"
},
"dependencies": {
"@types/estree": "1.0.5"
},
"devDependenciesComments": {

@@ -123,15 +128,15 @@ "@rollup/plugin-typescript": "It appears that 11.1.3 breaks sourcemaps"

"devDependencies": {
"@codemirror/commands": "^6.3.0",
"@codemirror/commands": "^6.3.3",
"@codemirror/lang-javascript": "^6.2.1",
"@codemirror/language": "^6.9.2",
"@codemirror/search": "^6.5.4",
"@codemirror/state": "^6.3.1",
"@codemirror/view": "^6.22.0",
"@codemirror/language": "^6.10.0",
"@codemirror/search": "^6.5.5",
"@codemirror/state": "^6.4.0",
"@codemirror/view": "^6.23.0",
"@jridgewell/sourcemap-codec": "^1.4.15",
"@mermaid-js/mermaid-cli": "^10.6.0",
"@napi-rs/cli": "^2.16.5",
"@rollup/plugin-alias": "^5.0.1",
"@mermaid-js/mermaid-cli": "^10.6.1",
"@napi-rs/cli": "^2.17.0",
"@rollup/plugin-alias": "^5.1.0",
"@rollup/plugin-buble": "^1.0.3",
"@rollup/plugin-commonjs": "^25.0.7",
"@rollup/plugin-json": "^6.0.1",
"@rollup/plugin-json": "^6.1.0",
"@rollup/plugin-node-resolve": "^15.2.3",

@@ -141,12 +146,12 @@ "@rollup/plugin-replace": "^5.0.5",

"@rollup/plugin-typescript": "11.1.5",
"@rollup/pluginutils": "^5.0.5",
"@types/estree": "1.0.5",
"@types/mocha": "^10.0.3",
"@rollup/pluginutils": "^5.1.0",
"@types/inquirer": "^9.0.7",
"@types/mocha": "^10.0.6",
"@types/node": "18.0.0",
"@types/yargs-parser": "^21.0.2",
"@typescript-eslint/eslint-plugin": "^6.10.0",
"@typescript-eslint/parser": "^6.10.0",
"@vue/eslint-config-prettier": "^8.0.0",
"@types/yargs-parser": "^21.0.3",
"@typescript-eslint/eslint-plugin": "^6.17.0",
"@typescript-eslint/parser": "^6.17.0",
"@vue/eslint-config-prettier": "^9.0.0",
"@vue/eslint-config-typescript": "^12.0.0",
"acorn": "^8.11.2",
"acorn": "^8.11.3",
"acorn-import-assertions": "^1.9.0",

@@ -158,20 +163,20 @@ "buble": "^0.20.0",

"concurrently": "^8.2.2",
"core-js": "^3.33.2",
"core-js": "^3.35.0",
"date-time": "^4.0.0",
"es5-shim": "^4.6.7",
"es6-shim": "^0.35.8",
"eslint": "^8.53.0",
"eslint-config-prettier": "^9.0.0",
"eslint-plugin-import": "^2.29.0",
"eslint-plugin-prettier": "^5.0.1",
"eslint-plugin-unicorn": "^49.0.0",
"eslint-plugin-vue": "^9.18.1",
"eslint": "^8.56.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-prettier": "^5.1.2",
"eslint-plugin-unicorn": "^50.0.1",
"eslint-plugin-vue": "^9.19.2",
"fixturify": "^3.0.0",
"flru": "^1.0.2",
"fs-extra": "^11.1.1",
"fs-extra": "^11.2.0",
"github-api": "^3.4.0",
"husky": "^8.0.3",
"inquirer": "^9.2.11",
"inquirer": "^9.2.12",
"is-reference": "^3.0.2",
"lint-staged": "^15.0.2",
"lint-staged": "^15.2.0",
"locate-character": "^3.0.0",

@@ -182,10 +187,9 @@ "magic-string": "^0.30.5",

"pinia": "^2.1.7",
"prettier": "^3.0.3",
"prettier": "^3.1.1",
"pretty-bytes": "^6.1.1",
"pretty-ms": "^8.0.0",
"requirejs": "^2.3.6",
"rollup": "^4.3.1",
"rollup": "^4.9.2",
"rollup-plugin-license": "^3.2.0",
"rollup-plugin-string": "^3.0.0",
"rollup-plugin-thatworks": "^1.0.4",
"semver": "^7.5.4",

@@ -196,9 +200,9 @@ "shx": "^0.3.4",

"source-map-support": "^0.5.21",
"systemjs": "^6.14.2",
"terser": "^5.24.0",
"systemjs": "^6.14.3",
"terser": "^5.26.0",
"tslib": "^2.6.2",
"typescript": "^5.2.2",
"vite": "^4.5.0",
"vitepress": "^1.0.0-rc.25",
"vue": "^3.3.8",
"typescript": "^5.3.3",
"vite": "^5.0.10",
"vitepress": "^1.0.0-rc.34",
"vue": "^3.4.3",
"wasm-pack": "^0.12.1",

@@ -209,3 +213,3 @@ "weak-napi": "^2.0.2",

"overrides": {
"axios": "^1.6.0",
"axios": "^1.6.3",
"semver": "^7.5.4"

@@ -212,0 +216,0 @@ },

@@ -9,2 +9,5 @@ <p align="center">

</a>
<a href="https://nodejs.org/en/about/previous-releases">
<img src="https://img.shields.io/node/v/rollup.svg" alt="node compatibility">
</a>
<a href="https://packagephobia.now.sh/result?p=rollup">

@@ -17,3 +20,3 @@ <img src="https://packagephobia.now.sh/badge?p=rollup" alt="install size" >

<a href="#backers" alt="sponsors on Open Collective">
<img src="https://opencollective.com/rollup/backers/badge.svg" alt="backers" >
<img src="https://opencollective.com/rollup/backers/badge.svg" alt="backers" >
</a>

@@ -26,3 +29,2 @@ <a href="#sponsors" alt="Sponsors on Open Collective">

</a>
<a href='https://is.gd/rollup_chat?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge'>

@@ -126,4 +128,10 @@ <img src='https://img.shields.io/discord/466787075518365708?color=778cd1&label=chat' alt='Join the chat at https://is.gd/rollup_chat'>

## Special Sponsor
<a href="https://www.tngtech.com/en/index.html" target="_blank"><img src="https://www.tngtech.com/fileadmin/Public/Images/Logos/TNG_Logo_medium_400x64.svg" alt="TNG Logo" width="280"/></a>
TNG has been supporting the work of [Lukas Taegert-Atkinson](https://github.com/lukastaegert) on Rollup since 2017.
## License
[MIT](https://github.com/rollup/rollup/blob/master/LICENSE.md)

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc