Socket
Socket
Sign inDemoInstall

@azure/abort-controller

Package Overview
Dependencies
Maintainers
1
Versions
329
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@azure/abort-controller - npm Package Compare versions

Comparing version 1.0.0 to 1.0.1-alpha.20200922.1

CHANGELOG.md

5

dist-esm/src/AbortController.js

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

// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
import { __extends } from "tslib";

@@ -70,2 +72,3 @@ import { AbortSignal, abortSignal } from "./AbortSignal";

if (!Array.isArray(parentSignals)) {
// eslint-disable-next-line prefer-rest-params
parentSignals = arguments;

@@ -100,3 +103,3 @@ }

},
enumerable: true,
enumerable: false,
configurable: true

@@ -103,0 +106,0 @@ });

12

dist-esm/src/AbortSignal.js

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

// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
var listenersMap = new WeakMap();

@@ -43,3 +45,3 @@ var abortedMap = new WeakMap();

},
enumerable: true,
enumerable: false,
configurable: true

@@ -59,3 +61,3 @@ });

},
enumerable: true,
enumerable: false,
configurable: true

@@ -99,5 +101,5 @@ });

/**
* Dispatches a synthetic event to the AbortSignal.
*/
AbortSignal.prototype.dispatchEvent = function (event) {
* Dispatches a synthetic event to the AbortSignal.
*/
AbortSignal.prototype.dispatchEvent = function (_event) {
throw new Error("This is a stub dispatchEvent implementation that should not be used. It only exists for type-checking purposes.");

@@ -104,0 +106,0 @@ };

@@ -7,2 +7,4 @@ 'use strict';

// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
var listenersMap = new WeakMap();

@@ -50,3 +52,3 @@ var abortedMap = new WeakMap();

},
enumerable: true,
enumerable: false,
configurable: true

@@ -66,3 +68,3 @@ });

},
enumerable: true,
enumerable: false,
configurable: true

@@ -106,5 +108,5 @@ });

/**
* Dispatches a synthetic event to the AbortSignal.
*/
AbortSignal.prototype.dispatchEvent = function (event) {
* Dispatches a synthetic event to the AbortSignal.
*/
AbortSignal.prototype.dispatchEvent = function (_event) {
throw new Error("This is a stub dispatchEvent implementation that should not be used. It only exists for type-checking purposes.");

@@ -140,2 +142,3 @@ };

// Copyright (c) Microsoft Corporation.
/**

@@ -207,2 +210,3 @@ * This error is thrown when an asynchronous operation has been aborted.

if (!Array.isArray(parentSignals)) {
// eslint-disable-next-line prefer-rest-params
parentSignals = arguments;

@@ -237,3 +241,3 @@ }

},
enumerable: true,
enumerable: false,
configurable: true

@@ -240,0 +244,0 @@ });

{
"name": "@azure/abort-controller",
"sdk-type": "client",
"version": "1.0.0",
"version": "1.0.1-alpha.20200922.1",
"description": "Microsoft Azure SDK for JavaScript - Aborter",
"main": "./dist/index.js",
"module": "./dist-esm/src/aborter.js",
"module": "dist-esm/src/index.js",
"scripts": {

@@ -14,11 +14,12 @@ "audit": "node ../../../common/scripts/rush-audit.js && rimraf node_modules package-lock.json && npm i --package-lock-only 2>&1 && npm audit",

"build": "npm run build:es6 && npm run build:nodebrowser",
"check-format": "prettier --list-different --config ../../.prettierrc.json \"src/**/*.ts\" \"test/**/*.ts\" \"*.{js,json}\"",
"clean": "rimraf dist dist-esm dist-test types temp browser/*.js* browser/*.zip statistics.html coverage coverage-browser .nyc_output *.tgz *.log test*.xml TEST*.xml",
"check-format": "prettier --list-different --config ../../../.prettierrc.json --ignore-path ../../../.prettierignore \"src/**/*.ts\" \"test/**/*.ts\" \"*.{js,json}\"",
"clean": "rimraf dist dist-esm dist-test types temp dist-browser/*.js* dist-browser/*.zip statistics.html coverage coverage-browser .nyc_output *.tgz *.log test*.xml TEST*.xml",
"execute:samples": "echo skipped",
"extract-api": "tsc -p . && api-extractor run --local",
"format": "prettier --write --config ../../.prettierrc.json \"src/**/*.ts\" \"test/**/*.ts\" \"*.{js,json}\"",
"format": "prettier --write --config ../../../.prettierrc.json --ignore-path ../../../.prettierignore \"src/**/*.ts\" \"test/**/*.ts\" \"*.{js,json}\"",
"integration-test:browser": "echo skipped",
"integration-test:node": "echo skipped",
"integration-test": "npm run integration-test:node && npm run integration-test:browser",
"lint:fix": "eslint \"src/**/*.ts\" \"test/**/*.ts\" -c ../../.eslintrc.json --fix --fix-type [problem,suggestion]",
"lint": "eslint -c ../../.eslintrc.json src test --ext .ts -f html -o abort-controller-lintReport.html || exit 0",
"lint:fix": "eslint package.json api-extractor.json src test --ext .ts --fix --fix-type [problem,suggestion]",
"lint": "eslint package.json api-extractor.json src test --ext .ts",
"pack": "npm pack 2>&1",

@@ -31,6 +32,6 @@ "prebuild": "npm run clean",

"unit-test:browser": "karma start --single-run",
"unit-test:node": "cross-env TS_NODE_FILES=true TS_NODE_COMPILER_OPTIONS=\"{\\\"module\\\": \\\"commonjs\\\"}\" mocha --require ts-node/register --require source-map-support/register --reporter mocha-multi --reporter-options spec=-,mocha-junit-reporter=- --full-trace --no-timeouts test/*.spec.ts",
"unit-test:node": "cross-env TS_NODE_FILES=true TS_NODE_COMPILER_OPTIONS=\"{\\\"module\\\": \\\"commonjs\\\"}\" mocha --require ts-node/register --require source-map-support/register --reporter ../../../common/tools/mocha-multi-reporter.js --full-trace --no-timeouts test/*.spec.ts",
"unit-test": "npm run unit-test:node && npm run unit-test:browser"
},
"types": "./types/src/aborter.d.ts",
"types": "./types/src/index.d.ts",
"engine": {

@@ -42,19 +43,21 @@ "node": ">=8.0.0"

"dist-esm/src/",
"src/",
"shims-public.d.ts",
"types/src",
"tsconfig.json"
"README.md",
"LICENSE"
],
"repository": {
"type": "git",
"url": "git+https://github.com/Azure/azure-sdk-for-js.git"
"engines": {
"node": ">=8.0.0"
},
"repository": "github:Azure/azure-sdk-for-js",
"keywords": [
"Azure",
"Aborter",
"AbortSignal",
"Cancellation",
"Node.js",
"TypeScript",
"JavaScript",
"Browser"
"azure",
"aborter",
"abortsignal",
"cancellation",
"node.js",
"typescript",
"javascript",
"browser",
"cloud"
],

@@ -66,10 +69,15 @@ "author": "Microsoft Corporation",

},
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/core/abort-controller",
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/core/abort-controller/README.md",
"sideEffects": false,
"dependencies": {
"tslib": "^1.9.3"
"tslib": "^2.0.0"
},
"devDependencies": {
"@microsoft/api-extractor": "^7.1.5",
"@types/mocha": "^5.2.5",
"@azure/eslint-plugin-azure-sdk": "^3.0.0-alpha",
"@microsoft/api-extractor": "7.7.11",
"@rollup/plugin-commonjs": "11.0.2",
"@rollup/plugin-multi-entry": "^3.0.0",
"@rollup/plugin-node-resolve": "^8.0.0",
"@rollup/plugin-replace": "^2.2.0",
"@types/mocha": "^7.0.2",
"@types/node": "^8.0.0",

@@ -79,3 +87,3 @@ "@typescript-eslint/eslint-plugin": "^2.0.0",

"assert": "^1.4.1",
"cross-env": "^5.2.0",
"cross-env": "^7.0.2",
"delay": "^4.2.0",

@@ -87,3 +95,3 @@ "eslint": "^6.1.0",

"eslint-plugin-promise": "^4.1.1",
"karma": "^4.0.1",
"karma": "^5.1.0",
"karma-chrome-launcher": "^3.0.0",

@@ -95,9 +103,8 @@ "karma-coverage": "^2.0.0",

"karma-ie-launcher": "^1.0.0",
"karma-junit-reporter": "^1.2.0",
"karma-mocha": "^1.3.0",
"karma-junit-reporter": "^2.0.1",
"karma-mocha": "^2.0.1",
"karma-mocha-reporter": "^2.2.5",
"karma-remap-coverage": "^0.1.5",
"mocha": "^6.2.2",
"karma-remap-istanbul": "^0.6.0",
"mocha": "^7.1.1",
"mocha-junit-reporter": "^1.18.0",
"mocha-multi": "^1.1.3",
"nyc": "^14.0.0",

@@ -107,11 +114,7 @@ "prettier": "^1.16.4",

"rollup": "^1.16.3",
"rollup-plugin-commonjs": "^10.0.0",
"rollup-plugin-multi-entry": "^2.1.0",
"rollup-plugin-node-resolve": "^5.0.2",
"rollup-plugin-replace": "^2.1.0",
"rollup-plugin-sourcemaps": "^0.4.2",
"rollup-plugin-terser": "^5.1.1",
"ts-node": "^8.3.0",
"typescript": "^3.2.2"
"typescript": "~3.9.3"
}
}

@@ -1,2 +0,2 @@

# Azure Abort Controller library for JS
# Azure Abort Controller library for JavaScript

@@ -13,3 +13,3 @@ The `@azure/abort-controller` package provides `AbortController` and `AbortSignal` classes. These classes are compatible

Install this libray using npm as follows
Install this library using npm as follows

@@ -95,14 +95,4 @@ ```

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor
License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your
contribution. For details, visit https://cla.microsoft.com.
If you'd like to contribute to this library, please read the [contributing guide](https://github.com/Azure/azure-sdk-for-js/blob/master/CONTRIBUTING.md) to learn more about how to build and test the code.
When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and
decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot.
You will only need to do this once across all repos using our CLA.
If you'd like to contribute to this library, please read the [contributing guide](https://github.com/Azure/azure-sdk-for-js/tree/64a0cf353678b313bc1c27b430803db431e49c4e/CONTRIBUTING.md) to learn more about how to build and test the code.
This project has adopted the Microsoft Open Source Code of Conduct.
For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional
questions or comments.
![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-js%2Fsdk%2Fcore%2Fabort-controller%2FREADME.png)

@@ -73,3 +73,3 @@ import { AbortSignal, AbortSignalLike } from "./AbortSignal";

*/
readonly signal: AbortSignal;
get signal(): AbortSignal;
/**

@@ -76,0 +76,0 @@ * Signal that any operations passed this controller's associated abort signal

@@ -1,2 +0,2 @@

/// <reference path="../../src/shims-public.d.ts" />
/// <reference path="../../shims-public.d.ts" />
/**

@@ -44,3 +44,3 @@ * Allows the request to be aborted upon firing of the "abort" event.

*/
readonly aborted: boolean;
get aborted(): boolean;
/**

@@ -54,3 +54,3 @@ * Creates a new AbortSignal instance that will never be aborted.

*/
static readonly none: AbortSignal;
static get none(): AbortSignal;
/**

@@ -79,6 +79,17 @@ * onabort event listener.

/**
* Dispatches a synthetic event to the AbortSignal.
*/
dispatchEvent(event: Event): boolean;
* Dispatches a synthetic event to the AbortSignal.
*/
dispatchEvent(_event: Event): boolean;
}
/**
* Helper to trigger an abort event immediately, the onabort and all abort event listeners will be triggered.
* Will try to trigger abort event for all linked AbortSignal nodes.
*
* - If there is a timeout, the timer will be cancelled.
* - If aborted is true, nothing will happen.
*
* @returns
* @internal
*/
export declare function abortSignal(signal: AbortSignal): void;
//# sourceMappingURL=AbortSignal.d.ts.map

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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