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

@rollup/plugin-alias

Package Overview
Dependencies
Maintainers
4
Versions
22
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@rollup/plugin-alias - npm Package Compare versions

Comparing version 3.1.1 to 3.1.2

11

CHANGELOG.md
# @rollup/plugin-alias ChangeLog
## v3.1.2
_2021-01-29_
### Updates
- chore: upgrade TypeScript (#708)
- chore: add missing readonly to internal function (#680)
- chore: fix TS error in function call (d04778c)
- chore: update dependencies (b3b8efd)
## v3.1.1

@@ -4,0 +15,0 @@

2

dist/index.es.js

@@ -82,3 +82,3 @@ import { platform } from 'os';

if (customResolver) {
return customResolver.call(this, updatedId, importerId);
return customResolver.call(this, updatedId, importerId, {});
}

@@ -85,0 +85,0 @@ return this.resolve(updatedId, importer, { skipSelf: true }).then((resolved) => {

'use strict';
function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
var os = require('os');
var slash = _interopDefault(require('slash'));
var slash = require('slash');
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
var slash__default = /*#__PURE__*/_interopDefaultLegacy(slash);
const VOLUME = /^([A-Z]:)/i;

@@ -27,3 +29,3 @@ const IS_WINDOWS = os.platform() === 'win32';

if (typeof id === 'string' && (IS_WINDOWS || VOLUME.test(id))) {
return slash(id.replace(VOLUME, ''));
return slash__default['default'](id.replace(VOLUME, ''));
}

@@ -87,3 +89,3 @@ return id;

if (customResolver) {
return customResolver.call(this, updatedId, importerId);
return customResolver.call(this, updatedId, importerId, {});
}

@@ -90,0 +92,0 @@ return this.resolve(updatedId, importer, { skipSelf: true }).then((resolved) => {

{
"name": "@rollup/plugin-alias",
"version": "3.1.1",
"version": "3.1.2",
"publishConfig": {

@@ -14,2 +14,3 @@ "access": "public"

"main": "dist/index.js",
"module": "dist/index.es.js",
"engines": {

@@ -25,3 +26,3 @@ "node": ">=8.0.0"

"lint": "pnpm run lint:js && pnpm run lint:docs && pnpm run lint:package",
"lint:docs": "prettier --single-quote --write README.md",
"lint:docs": "prettier --single-quote --arrow-parens avoid --trailing-comma none --write README.md",
"lint:js": "eslint --fix --cache src test types --ext .js,.ts",

@@ -54,9 +55,13 @@ "lint:package": "prettier --write package.json --plugin=prettier-plugin-package",

"devDependencies": {
"@rollup/plugin-node-resolve": "^7.0.0",
"@rollup/plugin-typescript": "^3.0.0",
"del-cli": "^3.0.0",
"rollup": "^2.0.0"
"@rollup/plugin-node-resolve": "^8.4.0",
"@rollup/plugin-typescript": "^5.0.2",
"del-cli": "^3.0.1",
"rollup": "^2.23.0",
"typescript": "^4.1.2"
},
"types": "types/index.d.ts",
"ava": {
"compileEnhancements": false,
"babel": {
"compileEnhancements": false
},
"extensions": [

@@ -75,5 +80,3 @@ "ts"

]
},
"module": "dist/index.es.js",
"types": "types/index.d.ts"
}
}
import { Plugin, PluginHooks } from 'rollup';
export interface Alias {
find: string | RegExp;
replacement: string;
customResolver?: ResolverFunction | ResolverObject | null;
}
export type ResolverFunction = PluginHooks['resolveId'];

@@ -16,2 +10,8 @@

export interface Alias {
find: string | RegExp;
replacement: string;
customResolver?: ResolverFunction | ResolverObject | null;
}
export interface RollupAliasOptions {

@@ -18,0 +18,0 @@ /**

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