new license file version [CI SKIP]

This commit is contained in:
2023-03-15 12:34:41 +00:00
parent 0a6d92a1f3
commit 61328d20ed
13115 changed files with 1892314 additions and 1 deletions

View File

@@ -0,0 +1 @@
module.exports={A:{A:{"2":"J D E F A B CC"},B:{"2":"C K L G M N O","33":"P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H"},C:{"1":"OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB","2":"0 1 2 3 4 5 6 7 8 9 DC tB I v J D E F A B C K L G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB EC FC"},D:{"16":"I v J D E F A B C K L G M N O","33":"0 1 2 3 4 5 6 7 8 9 w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB GC"},E:{"1":"3B 4B 5B sB 6B 7B 8B 9B OC","2":"I v HC zB IC","33":"J D E F A B C K L G JC KC LC 0B qB rB 1B MC NC 2B"},F:{"2":"F B C PC QC RC SC qB AC TC rB","33":"0 1 2 3 4 5 6 7 8 9 G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e"},G:{"1":"3B 4B 5B sB 6B 7B 8B 9B","16":"E zB UC BC VC WC XC YC ZC aC bC cC dC eC fC gC hC iC jC kC lC mC nC 2B"},H:{"2":"oC"},I:{"16":"tB I pC qC rC sC BC tC uC","33":"f"},J:{"16":"D A"},K:{"2":"A B C qB AC rB","33":"h"},L:{"16":"H"},M:{"1":"H"},N:{"16":"A B"},O:{"16":"vC"},P:{"16":"I g wC xC yC zC 0C 0B 1C 2C 3C 4C 5C sB 6C 7C 8C"},Q:{"33":"1B"},R:{"16":"9C"},S:{"1":"AD BD"}},B:4,C:"CSS print-color-adjust"};

View File

@@ -0,0 +1,4 @@
export type UserDeletionNotConfirmedError = {
name: string;
message: string;
};

View File

@@ -0,0 +1,21 @@
var Hash = require('./_Hash'),
ListCache = require('./_ListCache'),
Map = require('./_Map');
/**
* Removes all key-value entries from the map.
*
* @private
* @name clear
* @memberOf MapCache
*/
function mapCacheClear() {
this.size = 0;
this.__data__ = {
'hash': new Hash,
'map': new (Map || ListCache),
'string': new Hash
};
}
module.exports = mapCacheClear;

View File

@@ -0,0 +1,5 @@
var convert = require('./convert'),
func = convert('findIndex', require('../findIndex'));
func.placeholder = require('./placeholder');
module.exports = func;

View File

@@ -0,0 +1 @@
module.exports={C:{"35":0.00216,"52":0.01297,"72":0.03243,"78":0.06702,"80":0.14269,"96":0.00216,"99":0.00216,"101":0.05837,"102":0.02594,"105":0.00649,"108":0.03027,"109":0.47564,"110":0.25512,_:"2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 73 74 75 76 77 79 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 97 98 100 103 104 106 107 111 112 3.5 3.6"},D:{"27":0.00216,"32":0.00432,"35":0.00865,"38":0.00649,"39":0.00216,"41":0.00432,"44":0.0454,"47":0.00649,"49":0.0173,"56":0.00216,"59":0.00216,"62":0.01081,"63":0.00216,"65":0.00216,"67":0.00216,"68":0.00216,"69":0.0173,"70":0.00649,"71":0.0173,"74":0.00649,"75":0.02594,"76":0.00432,"78":0.00865,"79":0.05837,"80":0.00432,"81":0.01081,"83":0.00432,"84":0.03243,"85":0.01297,"86":0.29619,"87":0.2335,"88":0.00865,"89":0.02811,"90":0.01513,"91":0.00432,"92":0.01297,"93":0.01081,"94":0.00432,"95":0.01297,"96":0.04324,"97":0.01513,"98":0.01946,"99":0.0173,"100":0.02594,"101":0.00649,"102":0.03892,"103":0.02378,"104":0.01081,"105":0.03027,"106":0.1535,"107":0.07135,"108":0.14702,"109":7.98643,"110":2.95978,_:"4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 28 29 30 31 33 34 36 37 40 42 43 45 46 48 50 51 52 53 54 55 57 58 60 61 64 66 72 73 77 111 112 113"},F:{"36":0.0173,"62":0.00649,"68":0.00432,"71":0.00216,"72":0.00432,"74":0.00432,"79":0.05621,"80":0.00432,"82":0.00649,"84":0.00216,"85":0.01297,"86":0.00865,"87":0.00216,"88":0.00649,"89":0.00432,"91":0.00216,"92":0.00432,"93":0.00865,"94":0.32862,"95":0.58374,_:"9 11 12 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 60 63 64 65 66 67 69 70 73 75 76 77 78 81 83 90 9.5-9.6 10.6 11.1 11.5 11.6","10.0-10.1":0,"10.5":0.03459,"12.1":0.00432},B:{"13":0.01081,"14":0.00649,"16":0.01081,"18":0.0454,"84":0.00432,"89":0.00649,"92":0.0173,"98":0.00649,"100":0.00649,"103":0.00649,"106":0.00216,"107":0.00865,"108":0.01946,"109":0.65725,"110":0.42159,_:"12 15 17 79 80 81 83 85 86 87 88 90 91 93 94 95 96 97 99 101 102 104 105"},E:{"4":0,"13":0.00216,"14":0.02594,_:"0 5 6 7 8 9 10 11 12 15 3.1 3.2 6.1 7.1 9.1 10.1 11.1 16.4","5.1":0.4497,"12.1":0.00432,"13.1":0.00649,"14.1":0.04324,"15.1":0.0173,"15.2-15.3":0.03459,"15.4":0.00432,"15.5":0.0173,"15.6":0.09513,"16.0":0.03459,"16.1":0.03459,"16.2":0.07999,"16.3":0.18161},G:{"8":0.00281,"3.2":0,"4.0-4.1":0,"4.2-4.3":0,"5.0-5.1":0.01687,"6.0-6.1":0.00094,"7.0-7.1":0.01312,"8.1-8.4":0,"9.0-9.2":0.00094,"9.3":0.08436,"10.0-10.2":0,"10.3":0.02625,"11.0-11.2":0.0225,"11.3-11.4":0.01031,"12.0-12.1":0.0225,"12.2-12.5":0.53993,"13.0-13.1":0.01968,"13.2":0.00469,"13.3":0.05718,"13.4-13.7":0.08905,"14.0-14.4":0.31965,"14.5-14.8":0.25872,"15.0-15.1":0.15186,"15.2-15.3":0.25215,"15.4":0.17998,"15.5":0.33746,"15.6":0.55399,"16.0":1.32264,"16.1":1.37232,"16.2":1.13798,"16.3":1.73415,"16.4":0.01031},P:{"4":0.57071,"20":0.2344,"5.0-5.4":0.09172,"6.2-6.4":0.09172,"7.2-7.4":0.4688,"8.2":0.01016,"9.2":0.10191,"10.1":0.01019,"11.1-11.2":0.09172,"12.0":0.07134,"13.0":0.1223,"14.0":0.14268,"15.0":0.14268,"16.0":0.41784,"17.0":0.2344,"18.0":0.48918,"19.0":1.67138},I:{"0":0,"3":0,"4":0,"2.1":0,"2.2":0,"2.3":0,"4.1":0.00748,"4.2-4.3":0.00641,"4.4":0,"4.4.3-4.4.4":0.03313},K:{_:"0 10 11 12 11.1 11.5 12.1"},A:{"11":0.11459,_:"6 7 8 9 10 5.5"},N:{"10":0.03712,"11":0.07423},S:{"2.5":0,_:"3.0-3.1"},J:{"7":0,"10":0},O:{"0":1.18339},H:{"0":1.86231},L:{"0":63.04335},R:{_:"0"},M:{"0":0.04702},Q:{"13.1":0}};

View File

@@ -0,0 +1,31 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const stream_1 = require("stream");
const stream_2 = require("../readers/stream");
const provider_1 = require("./provider");
class ProviderStream extends provider_1.default {
constructor() {
super(...arguments);
this._reader = new stream_2.default(this._settings);
}
read(task) {
const root = this._getRootDirectory(task);
const options = this._getReaderOptions(task);
const source = this.api(root, task, options);
const destination = new stream_1.Readable({ objectMode: true, read: () => { } });
source
.once('error', (error) => destination.emit('error', error))
.on('data', (entry) => destination.emit('data', options.transform(entry)))
.once('end', () => destination.emit('end'));
destination
.once('close', () => source.destroy());
return destination;
}
api(root, task, options) {
if (task.dynamic) {
return this._reader.dynamic(root, options);
}
return this._reader.static(task.patterns, options);
}
}
exports.default = ProviderStream;

View File

@@ -0,0 +1 @@
{"version":3,"file":"firstValueFrom.d.ts","sourceRoot":"","sources":["../../../src/internal/firstValueFrom.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAI1C,MAAM,WAAW,oBAAoB,CAAC,CAAC;IACrC,YAAY,EAAE,CAAC,CAAC;CACjB;AAED,wBAAgB,cAAc,CAAC,CAAC,EAAE,CAAC,EAAE,MAAM,EAAE,UAAU,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,oBAAoB,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;AAC7G,wBAAgB,cAAc,CAAC,CAAC,EAAE,MAAM,EAAE,UAAU,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,CAAC"}

View File

@@ -0,0 +1,5 @@
var convert = require('./convert'),
func = convert('keysIn', require('../keysIn'), require('./_falseOptions'));
func.placeholder = require('./placeholder');
module.exports = func;

View File

@@ -0,0 +1,12 @@
# These are supported funding model platforms
github: [ljharb]
patreon: # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
ko_fi: # Replace with a single Ko-fi username
tidelift: npm/internal-slot
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
otechie: # Replace with a single Otechie username
custom: # Replace with a single custom sponsorship URL

View File

@@ -0,0 +1 @@
{"version":3,"file":"ExplorerSync.d.ts","sourceRoot":"","sources":["../src/ExplorerSync.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAG9C,OAAO,EACL,iBAAiB,EACjB,mBAAmB,EAEpB,MAAM,SAAS,CAAC;AAEjB,cAAM,YAAa,SAAQ,YAAY,CAAC,mBAAmB,CAAC;gBACvC,OAAO,EAAE,mBAAmB;IAIxC,UAAU,CAAC,UAAU,GAAE,MAAsB,GAAG,iBAAiB;IAUxE,OAAO,CAAC,uBAAuB;IAqB/B,OAAO,CAAC,mBAAmB;IAa3B,OAAO,CAAC,mBAAmB;IAO3B,OAAO,CAAC,mBAAmB;IAmB3B,OAAO,CAAC,2BAA2B;IAc5B,QAAQ,CAAC,QAAQ,EAAE,MAAM,GAAG,iBAAiB;IAIpD,OAAO,CAAC,aAAa;CAwBtB;AAED,OAAO,EAAE,YAAY,EAAE,CAAC"}

View File

@@ -0,0 +1,8 @@
import { Observable } from '../Observable';
import { OperatorFunction, TruthyTypesOf } from '../types';
export declare function last<T>(predicate: BooleanConstructor): OperatorFunction<T, TruthyTypesOf<T>>;
export declare function last<T, D>(predicate: BooleanConstructor, defaultValue: D): OperatorFunction<T, TruthyTypesOf<T> | D>;
export declare function last<T, D = T>(predicate?: null, defaultValue?: D): OperatorFunction<T, T | D>;
export declare function last<T, S extends T>(predicate: (value: T, index: number, source: Observable<T>) => value is S, defaultValue?: S): OperatorFunction<T, S>;
export declare function last<T, D = T>(predicate: (value: T, index: number, source: Observable<T>) => boolean, defaultValue?: D): OperatorFunction<T, T | D>;
//# sourceMappingURL=last.d.ts.map

View File

@@ -0,0 +1,24 @@
var arrayReduce = require('./_arrayReduce'),
deburr = require('./deburr'),
words = require('./words');
/** Used to compose unicode capture groups. */
var rsApos = "['\u2019]";
/** Used to match apostrophes. */
var reApos = RegExp(rsApos, 'g');
/**
* Creates a function like `_.camelCase`.
*
* @private
* @param {Function} callback The function to combine each word.
* @returns {Function} Returns the new compounder function.
*/
function createCompounder(callback) {
return function(string) {
return arrayReduce(words(deburr(string).replace(reApos, '')), callback, '');
};
}
module.exports = createCompounder;

View File

@@ -0,0 +1 @@
{"version":3,"file":"AnimationFrameScheduler.js","sourceRoot":"","sources":["../../../../src/internal/scheduler/AnimationFrameScheduler.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AACA,mDAAkD;AAElD;IAA6C,2CAAc;IAA3D;;IAkCA,CAAC;IAjCQ,uCAAK,GAAZ,UAAa,MAAyB;QACpC,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC;QAUpB,IAAM,OAAO,GAAG,IAAI,CAAC,UAAU,CAAC;QAChC,IAAI,CAAC,UAAU,GAAG,SAAS,CAAC;QAEpB,IAAA,OAAO,GAAK,IAAI,QAAT,CAAU;QACzB,IAAI,KAAU,CAAC;QACf,MAAM,GAAG,MAAM,IAAI,OAAO,CAAC,KAAK,EAAG,CAAC;QAEpC,GAAG;YACD,IAAI,CAAC,KAAK,GAAG,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,KAAK,EAAE,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE;gBACxD,MAAM;aACP;SACF,QAAQ,CAAC,MAAM,GAAG,OAAO,CAAC,CAAC,CAAC,CAAC,IAAI,MAAM,CAAC,EAAE,KAAK,OAAO,IAAI,OAAO,CAAC,KAAK,EAAE,EAAE;QAE5E,IAAI,CAAC,OAAO,GAAG,KAAK,CAAC;QAErB,IAAI,KAAK,EAAE;YACT,OAAO,CAAC,MAAM,GAAG,OAAO,CAAC,CAAC,CAAC,CAAC,IAAI,MAAM,CAAC,EAAE,KAAK,OAAO,IAAI,OAAO,CAAC,KAAK,EAAE,EAAE;gBACxE,MAAM,CAAC,WAAW,EAAE,CAAC;aACtB;YACD,MAAM,KAAK,CAAC;SACb;IACH,CAAC;IACH,8BAAC;AAAD,CAAC,AAlCD,CAA6C,+BAAc,GAkC1D;AAlCY,0DAAuB"}

View File

@@ -0,0 +1 @@
module.exports={A:{A:{"2":"J D E F A B CC"},B:{"1":"P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H","2":"C K L G M N O"},C:{"1":"AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB","2":"0 1 2 3 4 5 6 7 8 9 DC tB I v J D E F A B C K L G M N O w g x y z EC FC"},D:{"1":"SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB GC","2":"0 1 2 3 4 5 6 7 8 9 I v J D E F A B C K L G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB"},E:{"1":"A B C K L G LC 0B qB rB 1B MC NC 2B 3B 4B 5B sB 6B 7B 8B 9B OC","2":"I v J D E F HC zB IC JC KC"},F:{"1":"FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e","2":"0 1 2 3 4 5 6 7 8 9 F B C G M N O w g x y z AB BB CB DB EB PC QC RC SC qB AC TC rB"},G:{"1":"aC bC cC dC eC fC gC hC iC jC kC lC mC nC 2B 3B 4B 5B sB 6B 7B 8B 9B","2":"E zB UC BC VC WC XC YC ZC"},H:{"2":"oC"},I:{"1":"f","2":"tB I pC qC rC sC BC tC uC"},J:{"2":"D","16":"A"},K:{"1":"h","2":"A B C qB AC rB"},L:{"1":"H"},M:{"1":"H"},N:{"2":"A B"},O:{"1":"vC"},P:{"1":"g xC yC zC 0C 0B 1C 2C 3C 4C 5C sB 6C 7C 8C","2":"I wC"},Q:{"1":"1B"},R:{"1":"9C"},S:{"1":"AD BD"}},B:2,C:"CSS font-variant-numeric"};

View File

@@ -0,0 +1,21 @@
'use strict';
var allSettled = require('..');
var test = require('tape');
var runTests = require('./tests');
test('as a function', function (t) {
t.test('bad Promise/this value', function (st) {
// below test is skipped, because for convenience, i'm explicitly turning `undefined` into `Promise` in the main export
// eslint-disable-next-line no-useless-call
// st['throws'](function () { any.call(undefined, []); }, TypeError, 'undefined is not an object');
// eslint-disable-next-line no-useless-call
st['throws'](function () { allSettled.call(null, []); }, TypeError, 'null is not an object');
st.end();
});
runTests(allSettled, t);
t.end();
});

View File

@@ -0,0 +1,240 @@
import assert from './_assert.js';
import { sha256 } from './sha256.js';
import { pbkdf2 } from './pbkdf2.js';
import { asyncLoop, checkOpts, Input, u32 } from './utils.js';
// RFC 7914 Scrypt KDF
// Left rotate for uint32
const rotl = (a: number, b: number) => (a << b) | (a >>> (32 - b));
// The main Scrypt loop: uses Salsa extensively.
// Six versions of the function were tried, this is the fastest one.
// prettier-ignore
function XorAndSalsa(
prev: Uint32Array,
pi: number,
input: Uint32Array,
ii: number,
out: Uint32Array,
oi: number
) {
// Based on https://cr.yp.to/salsa20.html
// Xor blocks
let y00 = prev[pi++] ^ input[ii++], y01 = prev[pi++] ^ input[ii++];
let y02 = prev[pi++] ^ input[ii++], y03 = prev[pi++] ^ input[ii++];
let y04 = prev[pi++] ^ input[ii++], y05 = prev[pi++] ^ input[ii++];
let y06 = prev[pi++] ^ input[ii++], y07 = prev[pi++] ^ input[ii++];
let y08 = prev[pi++] ^ input[ii++], y09 = prev[pi++] ^ input[ii++];
let y10 = prev[pi++] ^ input[ii++], y11 = prev[pi++] ^ input[ii++];
let y12 = prev[pi++] ^ input[ii++], y13 = prev[pi++] ^ input[ii++];
let y14 = prev[pi++] ^ input[ii++], y15 = prev[pi++] ^ input[ii++];
// Save state to temporary variables (salsa)
let x00 = y00, x01 = y01, x02 = y02, x03 = y03,
x04 = y04, x05 = y05, x06 = y06, x07 = y07,
x08 = y08, x09 = y09, x10 = y10, x11 = y11,
x12 = y12, x13 = y13, x14 = y14, x15 = y15;
// Main loop (salsa)
for (let i = 0; i < 8; i += 2) {
x04 ^= rotl(x00 + x12 | 0, 7); x08 ^= rotl(x04 + x00 | 0, 9);
x12 ^= rotl(x08 + x04 | 0, 13); x00 ^= rotl(x12 + x08 | 0, 18);
x09 ^= rotl(x05 + x01 | 0, 7); x13 ^= rotl(x09 + x05 | 0, 9);
x01 ^= rotl(x13 + x09 | 0, 13); x05 ^= rotl(x01 + x13 | 0, 18);
x14 ^= rotl(x10 + x06 | 0, 7); x02 ^= rotl(x14 + x10 | 0, 9);
x06 ^= rotl(x02 + x14 | 0, 13); x10 ^= rotl(x06 + x02 | 0, 18);
x03 ^= rotl(x15 + x11 | 0, 7); x07 ^= rotl(x03 + x15 | 0, 9);
x11 ^= rotl(x07 + x03 | 0, 13); x15 ^= rotl(x11 + x07 | 0, 18);
x01 ^= rotl(x00 + x03 | 0, 7); x02 ^= rotl(x01 + x00 | 0, 9);
x03 ^= rotl(x02 + x01 | 0, 13); x00 ^= rotl(x03 + x02 | 0, 18);
x06 ^= rotl(x05 + x04 | 0, 7); x07 ^= rotl(x06 + x05 | 0, 9);
x04 ^= rotl(x07 + x06 | 0, 13); x05 ^= rotl(x04 + x07 | 0, 18);
x11 ^= rotl(x10 + x09 | 0, 7); x08 ^= rotl(x11 + x10 | 0, 9);
x09 ^= rotl(x08 + x11 | 0, 13); x10 ^= rotl(x09 + x08 | 0, 18);
x12 ^= rotl(x15 + x14 | 0, 7); x13 ^= rotl(x12 + x15 | 0, 9);
x14 ^= rotl(x13 + x12 | 0, 13); x15 ^= rotl(x14 + x13 | 0, 18);
}
// Write output (salsa)
out[oi++] = (y00 + x00) | 0; out[oi++] = (y01 + x01) | 0;
out[oi++] = (y02 + x02) | 0; out[oi++] = (y03 + x03) | 0;
out[oi++] = (y04 + x04) | 0; out[oi++] = (y05 + x05) | 0;
out[oi++] = (y06 + x06) | 0; out[oi++] = (y07 + x07) | 0;
out[oi++] = (y08 + x08) | 0; out[oi++] = (y09 + x09) | 0;
out[oi++] = (y10 + x10) | 0; out[oi++] = (y11 + x11) | 0;
out[oi++] = (y12 + x12) | 0; out[oi++] = (y13 + x13) | 0;
out[oi++] = (y14 + x14) | 0; out[oi++] = (y15 + x15) | 0;
}
function BlockMix(input: Uint32Array, ii: number, out: Uint32Array, oi: number, r: number) {
// The block B is r 128-byte chunks (which is equivalent of 2r 64-byte chunks)
let head = oi + 0;
let tail = oi + 16 * r;
for (let i = 0; i < 16; i++) out[tail + i] = input[ii + (2 * r - 1) * 16 + i]; // X ← B[2r1]
for (let i = 0; i < r; i++, head += 16, ii += 16) {
// We write odd & even Yi at same time. Even: 0bXXXXX0 Odd: 0bXXXXX1
XorAndSalsa(out, tail, input, ii, out, head); // head[i] = Salsa(blockIn[2*i] ^ tail[i-1])
if (i > 0) tail += 16; // First iteration overwrites tmp value in tail
XorAndSalsa(out, head, input, (ii += 16), out, tail); // tail[i] = Salsa(blockIn[2*i+1] ^ head[i])
}
}
export type ScryptOpts = {
N: number; // cost factor
r: number; // block size
p: number; // parallelization
dkLen?: number; // key length
asyncTick?: number; // block execution max time
maxmem?: number;
onProgress?: (progress: number) => void;
};
// Common prologue and epilogue for sync/async functions
function scryptInit(password: Input, salt: Input, _opts?: ScryptOpts) {
// Maxmem - 1GB+1KB by default
const opts = checkOpts(
{
dkLen: 32,
asyncTick: 10,
maxmem: 1024 ** 3 + 1024,
},
_opts
);
const { N, r, p, dkLen, asyncTick, maxmem, onProgress } = opts;
assert.number(N);
assert.number(r);
assert.number(p);
assert.number(dkLen);
assert.number(asyncTick);
assert.number(maxmem);
if (onProgress !== undefined && typeof onProgress !== 'function')
throw new Error('progressCb should be function');
const blockSize = 128 * r;
const blockSize32 = blockSize / 4;
if (N <= 1 || (N & (N - 1)) !== 0 || N >= 2 ** (blockSize / 8) || N > 2 ** 32) {
// NOTE: we limit N to be less than 2**32 because of 32 bit variant of Integrify function
// There is no JS engines that allows alocate more than 4GB per single Uint8Array for now, but can change in future.
throw new Error(
'Scrypt: N must be larger than 1, a power of 2, less than 2^(128 * r / 8) and less than 2^32'
);
}
if (p < 0 || p > ((2 ** 32 - 1) * 32) / blockSize) {
throw new Error(
'Scrypt: p must be a positive integer less than or equal to ((2^32 - 1) * 32) / (128 * r)'
);
}
if (dkLen < 0 || dkLen > (2 ** 32 - 1) * 32) {
throw new Error(
'Scrypt: dkLen should be positive integer less than or equal to (2^32 - 1) * 32'
);
}
const memUsed = blockSize * (N + p);
if (memUsed > maxmem) {
throw new Error(
`Scrypt: parameters too large, ${memUsed} (128 * r * (N + p)) > ${maxmem} (maxmem)`
);
}
// [B0...Bp1] ← PBKDF2HMAC-SHA256(Passphrase, Salt, 1, blockSize*ParallelizationFactor)
// Since it has only one iteration there is no reason to use async variant
const B = pbkdf2(sha256, password, salt, { c: 1, dkLen: blockSize * p });
const B32 = u32(B);
// Re-used between parallel iterations. Array(iterations) of B
const V = u32(new Uint8Array(blockSize * N));
const tmp = u32(new Uint8Array(blockSize));
let blockMixCb = () => {};
if (onProgress) {
const totalBlockMix = 2 * N * p;
// Invoke callback if progress changes from 10.01 to 10.02
// Allows to draw smooth progress bar on up to 8K screen
const callbackPer = Math.max(Math.floor(totalBlockMix / 10000), 1);
let blockMixCnt = 0;
blockMixCb = () => {
blockMixCnt++;
if (onProgress && (!(blockMixCnt % callbackPer) || blockMixCnt === totalBlockMix))
onProgress(blockMixCnt / totalBlockMix);
};
}
return { N, r, p, dkLen, blockSize32, V, B32, B, tmp, blockMixCb, asyncTick };
}
function scryptOutput(
password: Input,
dkLen: number,
B: Uint8Array,
V: Uint32Array,
tmp: Uint32Array
) {
const res = pbkdf2(sha256, password, B, { c: 1, dkLen });
B.fill(0);
V.fill(0);
tmp.fill(0);
return res;
}
/**
* Scrypt KDF from RFC 7914.
* @param password - pass
* @param salt - salt
* @param opts - parameters
* - `N` is cpu/mem work factor (power of 2 e.g. 2**18)
* - `r` is block size (8 is common), fine-tunes sequential memory read size and performance
* - `p` is parallelization factor (1 is common)
* - `dkLen` is output key length in bytes e.g. 32.
* - `asyncTick` - (default: 10) max time in ms for which async function can block execution
* - `maxmem` - (default: `1024 ** 3 + 1024` aka 1GB+1KB). A limit that the app could use for scrypt
* - `onProgress` - callback function that would be executed for progress report
* @returns Derived key
*/
export function scrypt(password: Input, salt: Input, opts: ScryptOpts) {
const { N, r, p, dkLen, blockSize32, V, B32, B, tmp, blockMixCb } = scryptInit(
password,
salt,
opts
);
for (let pi = 0; pi < p; pi++) {
const Pi = blockSize32 * pi;
for (let i = 0; i < blockSize32; i++) V[i] = B32[Pi + i]; // V[0] = B[i]
for (let i = 0, pos = 0; i < N - 1; i++) {
BlockMix(V, pos, V, (pos += blockSize32), r); // V[i] = BlockMix(V[i-1]);
blockMixCb();
}
BlockMix(V, (N - 1) * blockSize32, B32, Pi, r); // Process last element
blockMixCb();
for (let i = 0; i < N; i++) {
// First u32 of the last 64-byte block (u32 is LE)
const j = B32[Pi + blockSize32 - 16] % N; // j = Integrify(X) % iterations
for (let k = 0; k < blockSize32; k++) tmp[k] = B32[Pi + k] ^ V[j * blockSize32 + k]; // tmp = B ^ V[j]
BlockMix(tmp, 0, B32, Pi, r); // B = BlockMix(B ^ V[j])
blockMixCb();
}
}
return scryptOutput(password, dkLen, B, V, tmp);
}
/**
* Scrypt KDF from RFC 7914.
*/
export async function scryptAsync(password: Input, salt: Input, opts: ScryptOpts) {
const { N, r, p, dkLen, blockSize32, V, B32, B, tmp, blockMixCb, asyncTick } = scryptInit(
password,
salt,
opts
);
for (let pi = 0; pi < p; pi++) {
const Pi = blockSize32 * pi;
for (let i = 0; i < blockSize32; i++) V[i] = B32[Pi + i]; // V[0] = B[i]
let pos = 0;
await asyncLoop(N - 1, asyncTick, (i) => {
BlockMix(V, pos, V, (pos += blockSize32), r); // V[i] = BlockMix(V[i-1]);
blockMixCb();
});
BlockMix(V, (N - 1) * blockSize32, B32, Pi, r); // Process last element
blockMixCb();
await asyncLoop(N, asyncTick, (i) => {
// First u32 of the last 64-byte block (u32 is LE)
const j = B32[Pi + blockSize32 - 16] % N; // j = Integrify(X) % iterations
for (let k = 0; k < blockSize32; k++) tmp[k] = B32[Pi + k] ^ V[j * blockSize32 + k]; // tmp = B ^ V[j]
BlockMix(tmp, 0, B32, Pi, r); // B = BlockMix(B ^ V[j])
blockMixCb();
});
}
return scryptOutput(password, dkLen, B, V, tmp);
}

View File

@@ -0,0 +1,333 @@
// @ts-check
/** @typedef { import('estree').BaseNode} BaseNode */
/** @typedef {{
skip: () => void;
remove: () => void;
replace: (node: BaseNode) => void;
}} WalkerContext */
class WalkerBase {
constructor() {
/** @type {boolean} */
this.should_skip = false;
/** @type {boolean} */
this.should_remove = false;
/** @type {BaseNode | null} */
this.replacement = null;
/** @type {WalkerContext} */
this.context = {
skip: () => (this.should_skip = true),
remove: () => (this.should_remove = true),
replace: (node) => (this.replacement = node)
};
}
/**
*
* @param {any} parent
* @param {string} prop
* @param {number} index
* @param {BaseNode} node
*/
replace(parent, prop, index, node) {
if (parent) {
if (index !== null) {
parent[prop][index] = node;
} else {
parent[prop] = node;
}
}
}
/**
*
* @param {any} parent
* @param {string} prop
* @param {number} index
*/
remove(parent, prop, index) {
if (parent) {
if (index !== null) {
parent[prop].splice(index, 1);
} else {
delete parent[prop];
}
}
}
}
// @ts-check
/** @typedef { import('estree').BaseNode} BaseNode */
/** @typedef { import('./walker.js').WalkerContext} WalkerContext */
/** @typedef {(
* this: WalkerContext,
* node: BaseNode,
* parent: BaseNode,
* key: string,
* index: number
* ) => void} SyncHandler */
class SyncWalker extends WalkerBase {
/**
*
* @param {SyncHandler} enter
* @param {SyncHandler} leave
*/
constructor(enter, leave) {
super();
/** @type {SyncHandler} */
this.enter = enter;
/** @type {SyncHandler} */
this.leave = leave;
}
/**
*
* @param {BaseNode} node
* @param {BaseNode} parent
* @param {string} [prop]
* @param {number} [index]
* @returns {BaseNode}
*/
visit(node, parent, prop, index) {
if (node) {
if (this.enter) {
const _should_skip = this.should_skip;
const _should_remove = this.should_remove;
const _replacement = this.replacement;
this.should_skip = false;
this.should_remove = false;
this.replacement = null;
this.enter.call(this.context, node, parent, prop, index);
if (this.replacement) {
node = this.replacement;
this.replace(parent, prop, index, node);
}
if (this.should_remove) {
this.remove(parent, prop, index);
}
const skipped = this.should_skip;
const removed = this.should_remove;
this.should_skip = _should_skip;
this.should_remove = _should_remove;
this.replacement = _replacement;
if (skipped) return node;
if (removed) return null;
}
for (const key in node) {
const value = node[key];
if (typeof value !== "object") {
continue;
} else if (Array.isArray(value)) {
for (let i = 0; i < value.length; i += 1) {
if (value[i] !== null && typeof value[i].type === 'string') {
if (!this.visit(value[i], node, key, i)) {
// removed
i--;
}
}
}
} else if (value !== null && typeof value.type === "string") {
this.visit(value, node, key, null);
}
}
if (this.leave) {
const _replacement = this.replacement;
const _should_remove = this.should_remove;
this.replacement = null;
this.should_remove = false;
this.leave.call(this.context, node, parent, prop, index);
if (this.replacement) {
node = this.replacement;
this.replace(parent, prop, index, node);
}
if (this.should_remove) {
this.remove(parent, prop, index);
}
const removed = this.should_remove;
this.replacement = _replacement;
this.should_remove = _should_remove;
if (removed) return null;
}
}
return node;
}
}
// @ts-check
/** @typedef { import('estree').BaseNode} BaseNode */
/** @typedef { import('./walker').WalkerContext} WalkerContext */
/** @typedef {(
* this: WalkerContext,
* node: BaseNode,
* parent: BaseNode,
* key: string,
* index: number
* ) => Promise<void>} AsyncHandler */
class AsyncWalker extends WalkerBase {
/**
*
* @param {AsyncHandler} enter
* @param {AsyncHandler} leave
*/
constructor(enter, leave) {
super();
/** @type {AsyncHandler} */
this.enter = enter;
/** @type {AsyncHandler} */
this.leave = leave;
}
/**
*
* @param {BaseNode} node
* @param {BaseNode} parent
* @param {string} [prop]
* @param {number} [index]
* @returns {Promise<BaseNode>}
*/
async visit(node, parent, prop, index) {
if (node) {
if (this.enter) {
const _should_skip = this.should_skip;
const _should_remove = this.should_remove;
const _replacement = this.replacement;
this.should_skip = false;
this.should_remove = false;
this.replacement = null;
await this.enter.call(this.context, node, parent, prop, index);
if (this.replacement) {
node = this.replacement;
this.replace(parent, prop, index, node);
}
if (this.should_remove) {
this.remove(parent, prop, index);
}
const skipped = this.should_skip;
const removed = this.should_remove;
this.should_skip = _should_skip;
this.should_remove = _should_remove;
this.replacement = _replacement;
if (skipped) return node;
if (removed) return null;
}
for (const key in node) {
const value = node[key];
if (typeof value !== "object") {
continue;
} else if (Array.isArray(value)) {
for (let i = 0; i < value.length; i += 1) {
if (value[i] !== null && typeof value[i].type === 'string') {
if (!(await this.visit(value[i], node, key, i))) {
// removed
i--;
}
}
}
} else if (value !== null && typeof value.type === "string") {
await this.visit(value, node, key, null);
}
}
if (this.leave) {
const _replacement = this.replacement;
const _should_remove = this.should_remove;
this.replacement = null;
this.should_remove = false;
await this.leave.call(this.context, node, parent, prop, index);
if (this.replacement) {
node = this.replacement;
this.replace(parent, prop, index, node);
}
if (this.should_remove) {
this.remove(parent, prop, index);
}
const removed = this.should_remove;
this.replacement = _replacement;
this.should_remove = _should_remove;
if (removed) return null;
}
}
return node;
}
}
// @ts-check
/** @typedef { import('estree').BaseNode} BaseNode */
/** @typedef { import('./sync.js').SyncHandler} SyncHandler */
/** @typedef { import('./async.js').AsyncHandler} AsyncHandler */
/**
*
* @param {BaseNode} ast
* @param {{
* enter?: SyncHandler
* leave?: SyncHandler
* }} walker
* @returns {BaseNode}
*/
function walk(ast, { enter, leave }) {
const instance = new SyncWalker(enter, leave);
return instance.visit(ast, null);
}
/**
*
* @param {BaseNode} ast
* @param {{
* enter?: AsyncHandler
* leave?: AsyncHandler
* }} walker
* @returns {Promise<BaseNode>}
*/
async function asyncWalk(ast, { enter, leave }) {
const instance = new AsyncWalker(enter, leave);
return await instance.visit(ast, null);
}
export { asyncWalk, walk };

View File

@@ -0,0 +1,153 @@
{
"assert": true,
"node:assert": [">= 14.18 && < 15", ">= 16"],
"assert/strict": ">= 15",
"node:assert/strict": ">= 16",
"async_hooks": ">= 8",
"node:async_hooks": [">= 14.18 && < 15", ">= 16"],
"buffer_ieee754": ">= 0.5 && < 0.9.7",
"buffer": true,
"node:buffer": [">= 14.18 && < 15", ">= 16"],
"child_process": true,
"node:child_process": [">= 14.18 && < 15", ">= 16"],
"cluster": ">= 0.5",
"node:cluster": [">= 14.18 && < 15", ">= 16"],
"console": true,
"node:console": [">= 14.18 && < 15", ">= 16"],
"constants": true,
"node:constants": [">= 14.18 && < 15", ">= 16"],
"crypto": true,
"node:crypto": [">= 14.18 && < 15", ">= 16"],
"_debug_agent": ">= 1 && < 8",
"_debugger": "< 8",
"dgram": true,
"node:dgram": [">= 14.18 && < 15", ">= 16"],
"diagnostics_channel": [">= 14.17 && < 15", ">= 15.1"],
"node:diagnostics_channel": [">= 14.18 && < 15", ">= 16"],
"dns": true,
"node:dns": [">= 14.18 && < 15", ">= 16"],
"dns/promises": ">= 15",
"node:dns/promises": ">= 16",
"domain": ">= 0.7.12",
"node:domain": [">= 14.18 && < 15", ">= 16"],
"events": true,
"node:events": [">= 14.18 && < 15", ">= 16"],
"freelist": "< 6",
"fs": true,
"node:fs": [">= 14.18 && < 15", ">= 16"],
"fs/promises": [">= 10 && < 10.1", ">= 14"],
"node:fs/promises": [">= 14.18 && < 15", ">= 16"],
"_http_agent": ">= 0.11.1",
"node:_http_agent": [">= 14.18 && < 15", ">= 16"],
"_http_client": ">= 0.11.1",
"node:_http_client": [">= 14.18 && < 15", ">= 16"],
"_http_common": ">= 0.11.1",
"node:_http_common": [">= 14.18 && < 15", ">= 16"],
"_http_incoming": ">= 0.11.1",
"node:_http_incoming": [">= 14.18 && < 15", ">= 16"],
"_http_outgoing": ">= 0.11.1",
"node:_http_outgoing": [">= 14.18 && < 15", ">= 16"],
"_http_server": ">= 0.11.1",
"node:_http_server": [">= 14.18 && < 15", ">= 16"],
"http": true,
"node:http": [">= 14.18 && < 15", ">= 16"],
"http2": ">= 8.8",
"node:http2": [">= 14.18 && < 15", ">= 16"],
"https": true,
"node:https": [">= 14.18 && < 15", ">= 16"],
"inspector": ">= 8",
"node:inspector": [">= 14.18 && < 15", ">= 16"],
"_linklist": "< 8",
"module": true,
"node:module": [">= 14.18 && < 15", ">= 16"],
"net": true,
"node:net": [">= 14.18 && < 15", ">= 16"],
"node-inspect/lib/_inspect": ">= 7.6 && < 12",
"node-inspect/lib/internal/inspect_client": ">= 7.6 && < 12",
"node-inspect/lib/internal/inspect_repl": ">= 7.6 && < 12",
"os": true,
"node:os": [">= 14.18 && < 15", ">= 16"],
"path": true,
"node:path": [">= 14.18 && < 15", ">= 16"],
"path/posix": ">= 15.3",
"node:path/posix": ">= 16",
"path/win32": ">= 15.3",
"node:path/win32": ">= 16",
"perf_hooks": ">= 8.5",
"node:perf_hooks": [">= 14.18 && < 15", ">= 16"],
"process": ">= 1",
"node:process": [">= 14.18 && < 15", ">= 16"],
"punycode": ">= 0.5",
"node:punycode": [">= 14.18 && < 15", ">= 16"],
"querystring": true,
"node:querystring": [">= 14.18 && < 15", ">= 16"],
"readline": true,
"node:readline": [">= 14.18 && < 15", ">= 16"],
"readline/promises": ">= 17",
"node:readline/promises": ">= 17",
"repl": true,
"node:repl": [">= 14.18 && < 15", ">= 16"],
"smalloc": ">= 0.11.5 && < 3",
"_stream_duplex": ">= 0.9.4",
"node:_stream_duplex": [">= 14.18 && < 15", ">= 16"],
"_stream_transform": ">= 0.9.4",
"node:_stream_transform": [">= 14.18 && < 15", ">= 16"],
"_stream_wrap": ">= 1.4.1",
"node:_stream_wrap": [">= 14.18 && < 15", ">= 16"],
"_stream_passthrough": ">= 0.9.4",
"node:_stream_passthrough": [">= 14.18 && < 15", ">= 16"],
"_stream_readable": ">= 0.9.4",
"node:_stream_readable": [">= 14.18 && < 15", ">= 16"],
"_stream_writable": ">= 0.9.4",
"node:_stream_writable": [">= 14.18 && < 15", ">= 16"],
"stream": true,
"node:stream": [">= 14.18 && < 15", ">= 16"],
"stream/consumers": ">= 16.7",
"node:stream/consumers": ">= 16.7",
"stream/promises": ">= 15",
"node:stream/promises": ">= 16",
"stream/web": ">= 16.5",
"node:stream/web": ">= 16.5",
"string_decoder": true,
"node:string_decoder": [">= 14.18 && < 15", ">= 16"],
"sys": [">= 0.4 && < 0.7", ">= 0.8"],
"node:sys": [">= 14.18 && < 15", ">= 16"],
"node:test": ">= 18",
"timers": true,
"node:timers": [">= 14.18 && < 15", ">= 16"],
"timers/promises": ">= 15",
"node:timers/promises": ">= 16",
"_tls_common": ">= 0.11.13",
"node:_tls_common": [">= 14.18 && < 15", ">= 16"],
"_tls_legacy": ">= 0.11.3 && < 10",
"_tls_wrap": ">= 0.11.3",
"node:_tls_wrap": [">= 14.18 && < 15", ">= 16"],
"tls": true,
"node:tls": [">= 14.18 && < 15", ">= 16"],
"trace_events": ">= 10",
"node:trace_events": [">= 14.18 && < 15", ">= 16"],
"tty": true,
"node:tty": [">= 14.18 && < 15", ">= 16"],
"url": true,
"node:url": [">= 14.18 && < 15", ">= 16"],
"util": true,
"node:util": [">= 14.18 && < 15", ">= 16"],
"util/types": ">= 15.3",
"node:util/types": ">= 16",
"v8/tools/arguments": ">= 10 && < 12",
"v8/tools/codemap": [">= 4.4 && < 5", ">= 5.2 && < 12"],
"v8/tools/consarray": [">= 4.4 && < 5", ">= 5.2 && < 12"],
"v8/tools/csvparser": [">= 4.4 && < 5", ">= 5.2 && < 12"],
"v8/tools/logreader": [">= 4.4 && < 5", ">= 5.2 && < 12"],
"v8/tools/profile_view": [">= 4.4 && < 5", ">= 5.2 && < 12"],
"v8/tools/splaytree": [">= 4.4 && < 5", ">= 5.2 && < 12"],
"v8": ">= 1",
"node:v8": [">= 14.18 && < 15", ">= 16"],
"vm": true,
"node:vm": [">= 14.18 && < 15", ">= 16"],
"wasi": ">= 13.4 && < 13.5",
"worker_threads": ">= 11.7",
"node:worker_threads": [">= 14.18 && < 15", ">= 16"],
"zlib": ">= 0.5",
"node:zlib": [">= 14.18 && < 15", ">= 16"]
}

View File

@@ -0,0 +1,70 @@
{
"name": "supports-preserve-symlinks-flag",
"version": "1.0.0",
"description": "Determine if the current node version supports the `--preserve-symlinks` flag.",
"main": "./index.js",
"browser": "./browser.js",
"exports": {
".": [
{
"browser": "./browser.js",
"default": "./index.js"
},
"./index.js"
],
"./package.json": "./package.json"
},
"sideEffects": false,
"scripts": {
"prepublishOnly": "safe-publish-latest",
"prepublish": "not-in-publish || npm run prepublishOnly",
"lint": "eslint --ext=js,mjs .",
"pretest": "npm run lint",
"tests-only": "nyc tape 'test/**/*.js'",
"test": "npm run tests-only",
"posttest": "aud --production",
"version": "auto-changelog && git add CHANGELOG.md",
"postversion": "auto-changelog && git add CHANGELOG.md && git commit --no-edit --amend && git tag -f \"v$(node -e \"console.log(require('./package.json').version)\")\""
},
"repository": {
"type": "git",
"url": "git+https://github.com/inspect-js/node-supports-preserve-symlinks-flag.git"
},
"keywords": [
"node",
"flag",
"symlink",
"symlinks",
"preserve-symlinks"
],
"author": "Jordan Harband <ljharb@gmail.com>",
"funding": {
"url": "https://github.com/sponsors/ljharb"
},
"license": "MIT",
"bugs": {
"url": "https://github.com/inspect-js/node-supports-preserve-symlinks-flag/issues"
},
"homepage": "https://github.com/inspect-js/node-supports-preserve-symlinks-flag#readme",
"devDependencies": {
"@ljharb/eslint-config": "^20.1.0",
"aud": "^1.1.5",
"auto-changelog": "^2.3.0",
"eslint": "^8.6.0",
"nyc": "^10.3.2",
"safe-publish-latest": "^2.0.0",
"semver": "^6.3.0",
"tape": "^5.4.0"
},
"engines": {
"node": ">= 0.4"
},
"auto-changelog": {
"output": "CHANGELOG.md",
"template": "keepachangelog",
"unreleased": false,
"commitLimit": false,
"backfillLimit": false,
"hideCredit": true
}
}

View File

@@ -0,0 +1 @@
export declare function globalifySelector(selector: string): string;

View File

@@ -0,0 +1,107 @@
# <img src="docs_app/src/assets/images/logos/Rx_Logo_S.png" alt="RxJS Logo" width="86" height="86"> RxJS: Reactive Extensions For JavaScript
![CI](https://github.com/reactivex/rxjs/workflows/CI/badge.svg)
[![npm version](https://badge.fury.io/js/rxjs.svg)](http://badge.fury.io/js/rxjs)
[![Join the chat at https://gitter.im/Reactive-Extensions/RxJS](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/Reactive-Extensions/RxJS?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
# The Roadmap from RxJS 7 to 8
Curious what's next for RxJS? Follow along with [Issue 6367](https://github.com/ReactiveX/rxjs/issues/6367).
# RxJS 7
### FOR 6.X PLEASE GO TO [THE 6.x BRANCH](https://github.com/ReactiveX/rxjs/tree/6.x)
Reactive Extensions Library for JavaScript. This is a rewrite of [Reactive-Extensions/RxJS](https://github.com/Reactive-Extensions/RxJS) and is the latest production-ready version of RxJS. This rewrite is meant to have better performance, better modularity, better debuggable call stacks, while staying mostly backwards compatible, with some breaking changes that reduce the API surface.
[Apache 2.0 License](LICENSE.txt)
- [Code of Conduct](CODE_OF_CONDUCT.md)
- [Contribution Guidelines](CONTRIBUTING.md)
- [Maintainer Guidelines](docs_app/content/maintainer-guidelines.md)
- [API Documentation](https://rxjs.dev/)
## Versions In This Repository
- [master](https://github.com/ReactiveX/rxjs/commits/master) - This is all of the current work, which is against v7 of RxJS right now
- [6.x](https://github.com/ReactiveX/rxjs/tree/6.x) - This is the branch for version 6.X
Most PRs should be made to **master**.
## Important
By contributing or commenting on issues in this repository, whether you've read them or not, you're agreeing to the [Contributor Code of Conduct](CODE_OF_CONDUCT.md). Much like traffic laws, ignorance doesn't grant you immunity.
## Installation and Usage
### ES6 via npm
```shell
npm install rxjs
```
It's recommended to pull in the Observable creation methods you need directly from `'rxjs'` as shown below with `range`.
If you're using RxJS version 7.2 or above, you can pull in any operator you need from the same spot, `'rxjs'`.
```ts
import { range, filter, map } from 'rxjs';
range(1, 200)
.pipe(
filter(x => x % 2 === 1),
map(x => x + x)
)
.subscribe(x => console.log(x));
```
If you're using RxJS version below 7.2, you can pull in any operator you need from one spot, under `'rxjs/operators'`.
```ts
import { range } from 'rxjs';
import { filter, map } from 'rxjs/operators';
range(1, 200)
.pipe(
filter(x => x % 2 === 1),
map(x => x + x)
)
.subscribe(x => console.log(x));
```
### CDN
For CDN, you can use [unpkg](https://unpkg.com/):
[https://unpkg.com/rxjs@^7/dist/bundles/rxjs.umd.min.js](https://unpkg.com/rxjs@%5E7/dist/bundles/rxjs.umd.min.js)
The global namespace for rxjs is `rxjs`:
```js
const { range } = rxjs;
const { filter, map } = rxjs.operators;
range(1, 200)
.pipe(
filter(x => x % 2 === 1),
map(x => x + x)
)
.subscribe(x => console.log(x));
```
## Goals
- Smaller overall bundles sizes
- Provide better performance than preceding versions of RxJS
- To model/follow the [Observable Spec Proposal](https://github.com/zenparsing/es-observable) to the observable
- Provide more modular file structure in a variety of formats
- Provide more debuggable call stacks than preceding versions of RxJS
## Building/Testing
- `npm run compile` build everything
- `npm test` run tests
- `npm run dtslint` run dtslint tests
## Adding documentation
We appreciate all contributions to the documentation of any type. All of the information needed to get the docs app up and running locally as well as how to contribute can be found in the [documentation directory](./docs_app).

View File

@@ -0,0 +1 @@
{"version":3,"file":"ResolveLocale.d.ts","sourceRoot":"","sources":["../../../../../../packages/intl-localematcher/abstract/ResolveLocale.ts"],"names":[],"mappings":"AAMA,MAAM,WAAW,mBAAmB;IAClC,MAAM,EAAE,MAAM,CAAA;IACd,UAAU,EAAE,MAAM,CAAA;IAClB,CAAC,CAAC,EAAE,MAAM,GAAG,GAAG,CAAA;CACjB;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,CAAC,SAAS,MAAM,EAAE,CAAC,SAAS;KAAE,CAAC,IAAI,CAAC,GAAG,GAAG;CAAC,EACvE,gBAAgB,EAAE,GAAG,CAAC,MAAM,CAAC,EAC7B,gBAAgB,EAAE,MAAM,EAAE,EAC1B,OAAO,EAAE;IAAC,aAAa,EAAE,MAAM,CAAC;IAAC,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;CAAC,EACrD,qBAAqB,EAAE,CAAC,EAAE,EAC1B,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,CAAC,GAAG,SAAS,CAAC,EACzC,gBAAgB,EAAE,MAAM,MAAM,GAC7B,mBAAmB,CA6ErB"}

View File

@@ -0,0 +1,5 @@
var convert = require('./convert'),
func = convert('mergeWith', require('../mergeWith'));
func.placeholder = require('./placeholder');
module.exports = func;

View File

@@ -0,0 +1,90 @@
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = isFQDN;
var _assertString = _interopRequireDefault(require("./util/assertString"));
var _merge = _interopRequireDefault(require("./util/merge"));
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
var default_fqdn_options = {
require_tld: true,
allow_underscores: false,
allow_trailing_dot: false,
allow_numeric_tld: false,
allow_wildcard: false,
ignore_max_length: false
};
function isFQDN(str, options) {
(0, _assertString.default)(str);
options = (0, _merge.default)(options, default_fqdn_options);
/* Remove the optional trailing dot before checking validity */
if (options.allow_trailing_dot && str[str.length - 1] === '.') {
str = str.substring(0, str.length - 1);
}
/* Remove the optional wildcard before checking validity */
if (options.allow_wildcard === true && str.indexOf('*.') === 0) {
str = str.substring(2);
}
var parts = str.split('.');
var tld = parts[parts.length - 1];
if (options.require_tld) {
// disallow fqdns without tld
if (parts.length < 2) {
return false;
}
if (!options.allow_numeric_tld && !/^([a-z\u00A1-\u00A8\u00AA-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]{2,}|xn[a-z0-9-]{2,})$/i.test(tld)) {
return false;
} // disallow spaces
if (/\s/.test(tld)) {
return false;
}
} // reject numeric TLDs
if (!options.allow_numeric_tld && /^\d+$/.test(tld)) {
return false;
}
return parts.every(function (part) {
if (part.length > 63 && !options.ignore_max_length) {
return false;
}
if (!/^[a-z_\u00a1-\uffff0-9-]+$/i.test(part)) {
return false;
} // disallow full-width chars
if (/[\uff01-\uff5e]/.test(part)) {
return false;
} // disallow parts starting or ending with hyphen
if (/^-|-$/.test(part)) {
return false;
}
if (!options.allow_underscores && /_/.test(part)) {
return false;
}
return true;
});
}
module.exports = exports.default;
module.exports.default = exports.default;

View File

@@ -0,0 +1,27 @@
var ListCache = require('./_ListCache'),
stackClear = require('./_stackClear'),
stackDelete = require('./_stackDelete'),
stackGet = require('./_stackGet'),
stackHas = require('./_stackHas'),
stackSet = require('./_stackSet');
/**
* Creates a stack cache object to store key-value pairs.
*
* @private
* @constructor
* @param {Array} [entries] The key-value pairs to cache.
*/
function Stack(entries) {
var data = this.__data__ = new ListCache(entries);
this.size = data.size;
}
// Add methods to `Stack`.
Stack.prototype.clear = stackClear;
Stack.prototype['delete'] = stackDelete;
Stack.prototype.get = stackGet;
Stack.prototype.has = stackHas;
Stack.prototype.set = stackSet;
module.exports = Stack;

View File

@@ -0,0 +1,75 @@
(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.immediate = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(_dereq_,module,exports){
(function (global){
'use strict';
var Mutation = global.MutationObserver || global.WebKitMutationObserver;
var scheduleDrain;
{
if (Mutation) {
var called = 0;
var observer = new Mutation(nextTick);
var element = global.document.createTextNode('');
observer.observe(element, {
characterData: true
});
scheduleDrain = function () {
element.data = (called = ++called % 2);
};
} else if (!global.setImmediate && typeof global.MessageChannel !== 'undefined') {
var channel = new global.MessageChannel();
channel.port1.onmessage = nextTick;
scheduleDrain = function () {
channel.port2.postMessage(0);
};
} else if ('document' in global && 'onreadystatechange' in global.document.createElement('script')) {
scheduleDrain = function () {
// Create a <script> element; its readystatechange event will be fired asynchronously once it is inserted
// into the document. Do so, thus queuing up the task. Remember to clean up once it's been called.
var scriptEl = global.document.createElement('script');
scriptEl.onreadystatechange = function () {
nextTick();
scriptEl.onreadystatechange = null;
scriptEl.parentNode.removeChild(scriptEl);
scriptEl = null;
};
global.document.documentElement.appendChild(scriptEl);
};
} else {
scheduleDrain = function () {
setTimeout(nextTick, 0);
};
}
}
var draining;
var queue = [];
//named nextTick for less confusing stack traces
function nextTick() {
draining = true;
var i, oldQueue;
var len = queue.length;
while (len) {
oldQueue = queue;
queue = [];
i = -1;
while (++i < len) {
oldQueue[i]();
}
len = queue.length;
}
draining = false;
}
module.exports = immediate;
function immediate(task) {
if (queue.push(task) === 1 && !draining) {
scheduleDrain();
}
}
}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
},{}]},{},[1])(1)
});

View File

@@ -0,0 +1,32 @@
import parser from 'postcss-selector-parser'
/**
* @template {string | import('postcss-selector-parser').Root} T
*
* Prefix all classes in the selector with the given prefix
*
* It can take either a string or a selector AST and will return the same type
*
* @param {string} prefix
* @param {T} selector
* @param {boolean} prependNegative
* @returns {T}
*/
export default function (prefix, selector, prependNegative = false) {
if (prefix === '') {
return selector
}
let ast = typeof selector === 'string' ? parser().astSync(selector) : selector
ast.walkClasses((classSelector) => {
let baseClass = classSelector.value
let shouldPlaceNegativeBeforePrefix = prependNegative && baseClass.startsWith('-')
classSelector.value = shouldPlaceNegativeBeforePrefix
? `-${prefix}${baseClass.slice(1)}`
: `${prefix}${baseClass}`
})
return typeof selector === 'string' ? ast.toString() : ast
}

View File

@@ -0,0 +1,39 @@
{
"name": "fast-levenshtein",
"version": "2.0.6",
"description": "Efficient implementation of Levenshtein algorithm with locale-specific collator support.",
"main": "levenshtein.js",
"files": [
"levenshtein.js"
],
"scripts": {
"build": "grunt build",
"prepublish": "npm run build",
"benchmark": "grunt benchmark",
"test": "mocha"
},
"devDependencies": {
"chai": "~1.5.0",
"grunt": "~0.4.1",
"grunt-benchmark": "~0.2.0",
"grunt-cli": "^1.2.0",
"grunt-contrib-jshint": "~0.4.3",
"grunt-contrib-uglify": "~0.2.0",
"grunt-mocha-test": "~0.2.2",
"grunt-npm-install": "~0.1.0",
"load-grunt-tasks": "~0.6.0",
"lodash": "^4.0.1",
"mocha": "~1.9.0"
},
"repository": {
"type": "git",
"url": "https://github.com/hiddentao/fast-levenshtein.git"
},
"keywords": [
"levenshtein",
"distance",
"string"
],
"author": "Ramesh Nair <ram@hiddentao.com> (http://www.hiddentao.com/)",
"license": "MIT"
}

View File

@@ -0,0 +1 @@
{"name":"isexe","version":"2.0.0","files":{"LICENSE":{"checkedAt":1678883670198,"integrity":"sha512-P6dI5Z+zrwxSk1MIRPqpYG2ScYNkidLIATQXd50QzBgBh/XmcEd/nsd9NB4O9k6rfc+4dsY5DwJ7xvhpoS0PRg==","mode":420,"size":765},"README.md":{"checkedAt":1678883670719,"integrity":"sha512-DJwm6tmkYCGZ0orwFZ65yjJHju3B00E/DTTRk3SUWItLj/TnEbN2A+57SP++UOFOD3idMToVRx3aZqh/DwYwmA==","mode":420,"size":1395},"package.json":{"checkedAt":1678883670719,"integrity":"sha512-RLgxDEcWHzAApGq5qcTqlQGJT/aZODLkrqT/EFdia4/1aUIET3L669j3YDzwXiw8T9GU/4OmDZzr4lTx3+WCpw==","mode":420,"size":786},"windows.js":{"checkedAt":1678883670719,"integrity":"sha512-5E6xcwFq7CTHcmP89dYkaK7mYDVnX9TcRWM3XtrEA+8P+iDGBH/qT0a1Ij9AIPVUR1hl4u1n1RFY4xr+oJf/BQ==","mode":420,"size":890},".npmignore":{"checkedAt":1678883670719,"integrity":"sha512-SEouI7JHh5Shi3XxY4b0OF6EiWcsI/tXVosxil5ZB/U5C9LHyrMvjcZ1hqx0HLdDIyIsW7LRkXlEbgQl2hFZAQ==","mode":420,"size":23},"index.js":{"checkedAt":1678883670719,"integrity":"sha512-iOrLyK6qYjFi5E34Sa7N0eNQQ7cm2lZ+Spfia/A1whE1fVXCDgy/iQBYO3zrFnfBgtl/qY2yi4bfLQyG2aJRew==","mode":420,"size":1192},"mode.js":{"checkedAt":1678883670719,"integrity":"sha512-/WVikdv8FbAnjlMfN/NhLqwQusbn9RbhRrlpT9FJ9H46fq2MGjo81B2rrX0NLdotl/bvlVnw+jXV3oPvh+QWjw==","mode":420,"size":909},"test/basic.js":{"checkedAt":1678883670719,"integrity":"sha512-elrA+uh57y6cfPrLNvcorbpYDuOA3sI2R+cTGIH1Jk+nq6Y8e4XBd75qLOZwJzbvljTkUrc49SlY58JUcWzZcA==","mode":420,"size":4996}}}

View File

@@ -0,0 +1,23 @@
const numeric = /^[0-9]+$/
const compareIdentifiers = (a, b) => {
const anum = numeric.test(a)
const bnum = numeric.test(b)
if (anum && bnum) {
a = +a
b = +b
}
return a === b ? 0
: (anum && !bnum) ? -1
: (bnum && !anum) ? 1
: a < b ? -1
: 1
}
const rcompareIdentifiers = (a, b) => compareIdentifiers(b, a)
module.exports = {
compareIdentifiers,
rcompareIdentifiers
}

View File

@@ -0,0 +1,7 @@
import { asyncScheduler } from '../scheduler/async';
import { audit } from './audit';
import { timer } from '../observable/timer';
export function auditTime(duration, scheduler = asyncScheduler) {
return audit(() => timer(duration, scheduler));
}
//# sourceMappingURL=auditTime.js.map

View File

@@ -0,0 +1,253 @@
"use strict";
var __assign = (this && this.__assign) || function () {
__assign = Object.assign || function(t) {
for (var s, i = 1, n = arguments.length; i < n; i++) {
s = arguments[i];
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
t[p] = s[p];
}
return t;
};
return __assign.apply(this, arguments);
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.fromAjax = exports.ajax = void 0;
var map_1 = require("../operators/map");
var Observable_1 = require("../Observable");
var AjaxResponse_1 = require("./AjaxResponse");
var errors_1 = require("./errors");
function ajaxGet(url, headers) {
return exports.ajax({ method: 'GET', url: url, headers: headers });
}
function ajaxPost(url, body, headers) {
return exports.ajax({ method: 'POST', url: url, body: body, headers: headers });
}
function ajaxDelete(url, headers) {
return exports.ajax({ method: 'DELETE', url: url, headers: headers });
}
function ajaxPut(url, body, headers) {
return exports.ajax({ method: 'PUT', url: url, body: body, headers: headers });
}
function ajaxPatch(url, body, headers) {
return exports.ajax({ method: 'PATCH', url: url, body: body, headers: headers });
}
var mapResponse = map_1.map(function (x) { return x.response; });
function ajaxGetJSON(url, headers) {
return mapResponse(exports.ajax({
method: 'GET',
url: url,
headers: headers,
}));
}
exports.ajax = (function () {
var create = function (urlOrConfig) {
var config = typeof urlOrConfig === 'string'
? {
url: urlOrConfig,
}
: urlOrConfig;
return fromAjax(config);
};
create.get = ajaxGet;
create.post = ajaxPost;
create.delete = ajaxDelete;
create.put = ajaxPut;
create.patch = ajaxPatch;
create.getJSON = ajaxGetJSON;
return create;
})();
var UPLOAD = 'upload';
var DOWNLOAD = 'download';
var LOADSTART = 'loadstart';
var PROGRESS = 'progress';
var LOAD = 'load';
function fromAjax(init) {
return new Observable_1.Observable(function (destination) {
var _a, _b;
var config = __assign({ async: true, crossDomain: false, withCredentials: false, method: 'GET', timeout: 0, responseType: 'json' }, init);
var queryParams = config.queryParams, configuredBody = config.body, configuredHeaders = config.headers;
var url = config.url;
if (!url) {
throw new TypeError('url is required');
}
if (queryParams) {
var searchParams_1;
if (url.includes('?')) {
var parts = url.split('?');
if (2 < parts.length) {
throw new TypeError('invalid url');
}
searchParams_1 = new URLSearchParams(parts[1]);
new URLSearchParams(queryParams).forEach(function (value, key) { return searchParams_1.set(key, value); });
url = parts[0] + '?' + searchParams_1;
}
else {
searchParams_1 = new URLSearchParams(queryParams);
url = url + '?' + searchParams_1;
}
}
var headers = {};
if (configuredHeaders) {
for (var key in configuredHeaders) {
if (configuredHeaders.hasOwnProperty(key)) {
headers[key.toLowerCase()] = configuredHeaders[key];
}
}
}
var crossDomain = config.crossDomain;
if (!crossDomain && !('x-requested-with' in headers)) {
headers['x-requested-with'] = 'XMLHttpRequest';
}
var withCredentials = config.withCredentials, xsrfCookieName = config.xsrfCookieName, xsrfHeaderName = config.xsrfHeaderName;
if ((withCredentials || !crossDomain) && xsrfCookieName && xsrfHeaderName) {
var xsrfCookie = (_b = (_a = document === null || document === void 0 ? void 0 : document.cookie.match(new RegExp("(^|;\\s*)(" + xsrfCookieName + ")=([^;]*)"))) === null || _a === void 0 ? void 0 : _a.pop()) !== null && _b !== void 0 ? _b : '';
if (xsrfCookie) {
headers[xsrfHeaderName] = xsrfCookie;
}
}
var body = extractContentTypeAndMaybeSerializeBody(configuredBody, headers);
var _request = __assign(__assign({}, config), { url: url,
headers: headers,
body: body });
var xhr;
xhr = init.createXHR ? init.createXHR() : new XMLHttpRequest();
{
var progressSubscriber_1 = init.progressSubscriber, _c = init.includeDownloadProgress, includeDownloadProgress = _c === void 0 ? false : _c, _d = init.includeUploadProgress, includeUploadProgress = _d === void 0 ? false : _d;
var addErrorEvent = function (type, errorFactory) {
xhr.addEventListener(type, function () {
var _a;
var error = errorFactory();
(_a = progressSubscriber_1 === null || progressSubscriber_1 === void 0 ? void 0 : progressSubscriber_1.error) === null || _a === void 0 ? void 0 : _a.call(progressSubscriber_1, error);
destination.error(error);
});
};
addErrorEvent('timeout', function () { return new errors_1.AjaxTimeoutError(xhr, _request); });
addErrorEvent('abort', function () { return new errors_1.AjaxError('aborted', xhr, _request); });
var createResponse_1 = function (direction, event) {
return new AjaxResponse_1.AjaxResponse(event, xhr, _request, direction + "_" + event.type);
};
var addProgressEvent_1 = function (target, type, direction) {
target.addEventListener(type, function (event) {
destination.next(createResponse_1(direction, event));
});
};
if (includeUploadProgress) {
[LOADSTART, PROGRESS, LOAD].forEach(function (type) { return addProgressEvent_1(xhr.upload, type, UPLOAD); });
}
if (progressSubscriber_1) {
[LOADSTART, PROGRESS].forEach(function (type) { return xhr.upload.addEventListener(type, function (e) { var _a; return (_a = progressSubscriber_1 === null || progressSubscriber_1 === void 0 ? void 0 : progressSubscriber_1.next) === null || _a === void 0 ? void 0 : _a.call(progressSubscriber_1, e); }); });
}
if (includeDownloadProgress) {
[LOADSTART, PROGRESS].forEach(function (type) { return addProgressEvent_1(xhr, type, DOWNLOAD); });
}
var emitError_1 = function (status) {
var msg = 'ajax error' + (status ? ' ' + status : '');
destination.error(new errors_1.AjaxError(msg, xhr, _request));
};
xhr.addEventListener('error', function (e) {
var _a;
(_a = progressSubscriber_1 === null || progressSubscriber_1 === void 0 ? void 0 : progressSubscriber_1.error) === null || _a === void 0 ? void 0 : _a.call(progressSubscriber_1, e);
emitError_1();
});
xhr.addEventListener(LOAD, function (event) {
var _a, _b;
var status = xhr.status;
if (status < 400) {
(_a = progressSubscriber_1 === null || progressSubscriber_1 === void 0 ? void 0 : progressSubscriber_1.complete) === null || _a === void 0 ? void 0 : _a.call(progressSubscriber_1);
var response = void 0;
try {
response = createResponse_1(DOWNLOAD, event);
}
catch (err) {
destination.error(err);
return;
}
destination.next(response);
destination.complete();
}
else {
(_b = progressSubscriber_1 === null || progressSubscriber_1 === void 0 ? void 0 : progressSubscriber_1.error) === null || _b === void 0 ? void 0 : _b.call(progressSubscriber_1, event);
emitError_1(status);
}
});
}
var user = _request.user, method = _request.method, async = _request.async;
if (user) {
xhr.open(method, url, async, user, _request.password);
}
else {
xhr.open(method, url, async);
}
if (async) {
xhr.timeout = _request.timeout;
xhr.responseType = _request.responseType;
}
if ('withCredentials' in xhr) {
xhr.withCredentials = _request.withCredentials;
}
for (var key in headers) {
if (headers.hasOwnProperty(key)) {
xhr.setRequestHeader(key, headers[key]);
}
}
if (body) {
xhr.send(body);
}
else {
xhr.send();
}
return function () {
if (xhr && xhr.readyState !== 4) {
xhr.abort();
}
};
});
}
exports.fromAjax = fromAjax;
function extractContentTypeAndMaybeSerializeBody(body, headers) {
var _a;
if (!body ||
typeof body === 'string' ||
isFormData(body) ||
isURLSearchParams(body) ||
isArrayBuffer(body) ||
isFile(body) ||
isBlob(body) ||
isReadableStream(body)) {
return body;
}
if (isArrayBufferView(body)) {
return body.buffer;
}
if (typeof body === 'object') {
headers['content-type'] = (_a = headers['content-type']) !== null && _a !== void 0 ? _a : 'application/json;charset=utf-8';
return JSON.stringify(body);
}
throw new TypeError('Unknown body type');
}
var _toString = Object.prototype.toString;
function toStringCheck(obj, name) {
return _toString.call(obj) === "[object " + name + "]";
}
function isArrayBuffer(body) {
return toStringCheck(body, 'ArrayBuffer');
}
function isFile(body) {
return toStringCheck(body, 'File');
}
function isBlob(body) {
return toStringCheck(body, 'Blob');
}
function isArrayBufferView(body) {
return typeof ArrayBuffer !== 'undefined' && ArrayBuffer.isView(body);
}
function isFormData(body) {
return typeof FormData !== 'undefined' && body instanceof FormData;
}
function isURLSearchParams(body) {
return typeof URLSearchParams !== 'undefined' && body instanceof URLSearchParams;
}
function isReadableStream(body) {
return typeof ReadableStream !== 'undefined' && body instanceof ReadableStream;
}
//# sourceMappingURL=ajax.js.map

View File

@@ -0,0 +1,125 @@
import { Observable } from '../Observable';
import { Subscriber } from '../Subscriber';
import { SchedulerLike } from '../types';
import { isFunction } from '../util/isFunction';
/**
* Creates an observable that will create an error instance and push it to the consumer as an error
* immediately upon subscription.
*
* <span class="informal">Just errors and does nothing else</span>
*
* ![](throw.png)
*
* This creation function is useful for creating an observable that will create an error and error every
* time it is subscribed to. Generally, inside of most operators when you might want to return an errored
* observable, this is unnecessary. In most cases, such as in the inner return of {@link concatMap},
* {@link mergeMap}, {@link defer}, and many others, you can simply throw the error, and RxJS will pick
* that up and notify the consumer of the error.
*
* ## Example
*
* Create a simple observable that will create a new error with a timestamp and log it
* and the message every time you subscribe to it
*
* ```ts
* import { throwError } from 'rxjs';
*
* let errorCount = 0;
*
* const errorWithTimestamp$ = throwError(() => {
* const error: any = new Error(`This is error number ${ ++errorCount }`);
* error.timestamp = Date.now();
* return error;
* });
*
* errorWithTimestamp$.subscribe({
* error: err => console.log(err.timestamp, err.message)
* });
*
* errorWithTimestamp$.subscribe({
* error: err => console.log(err.timestamp, err.message)
* });
*
* // Logs the timestamp and a new error message for each subscription
* ```
*
* ### Unnecessary usage
*
* Using `throwError` inside of an operator or creation function
* with a callback, is usually not necessary
*
* ```ts
* import { of, concatMap, timer, throwError } from 'rxjs';
*
* const delays$ = of(1000, 2000, Infinity, 3000);
*
* delays$.pipe(
* concatMap(ms => {
* if (ms < 10000) {
* return timer(ms);
* } else {
* // This is probably overkill.
* return throwError(() => new Error(`Invalid time ${ ms }`));
* }
* })
* )
* .subscribe({
* next: console.log,
* error: console.error
* });
* ```
*
* You can just throw the error instead
*
* ```ts
* import { of, concatMap, timer } from 'rxjs';
*
* const delays$ = of(1000, 2000, Infinity, 3000);
*
* delays$.pipe(
* concatMap(ms => {
* if (ms < 10000) {
* return timer(ms);
* } else {
* // Cleaner and easier to read for most folks.
* throw new Error(`Invalid time ${ ms }`);
* }
* })
* )
* .subscribe({
* next: console.log,
* error: console.error
* });
* ```
*
* @param errorFactory A factory function that will create the error instance that is pushed.
*/
export function throwError(errorFactory: () => any): Observable<never>;
/**
* Returns an observable that will error with the specified error immediately upon subscription.
*
* @param error The error instance to emit
* @deprecated Support for passing an error value will be removed in v8. Instead, pass a factory function to `throwError(() => new Error('test'))`. This is
* because it will create the error at the moment it should be created and capture a more appropriate stack trace. If
* for some reason you need to create the error ahead of time, you can still do that: `const err = new Error('test'); throwError(() => err);`.
*/
export function throwError(error: any): Observable<never>;
/**
* Notifies the consumer of an error using a given scheduler by scheduling it at delay `0` upon subscription.
*
* @param errorOrErrorFactory An error instance or error factory
* @param scheduler A scheduler to use to schedule the error notification
* @deprecated The `scheduler` parameter will be removed in v8.
* Use `throwError` in combination with {@link observeOn}: `throwError(() => new Error('test')).pipe(observeOn(scheduler));`.
* Details: https://rxjs.dev/deprecations/scheduler-argument
*/
export function throwError(errorOrErrorFactory: any, scheduler: SchedulerLike): Observable<never>;
export function throwError(errorOrErrorFactory: any, scheduler?: SchedulerLike): Observable<never> {
const errorFactory = isFunction(errorOrErrorFactory) ? errorOrErrorFactory : () => errorOrErrorFactory;
const init = (subscriber: Subscriber<never>) => subscriber.error(errorFactory());
return new Observable(scheduler ? (subscriber) => scheduler.schedule(init as any, 0, subscriber) : init);
}

View File

@@ -0,0 +1,3 @@
'use strict';
module.exports = require('./async').forEachOfLimit;

View File

@@ -0,0 +1,105 @@
<!doctype html>
<html lang="en">
<head>
<title>Code coverage report for csv2json/libs/core/defaultParsers/parser_array.js</title>
<meta charset="utf-8" />
<link rel="stylesheet" href="../../../../prettify.css" />
<link rel="stylesheet" href="../../../../base.css" />
<meta name="viewport" content="width=device-width, initial-scale=1">
<style type='text/css'>
.coverage-summary .sorter {
background-image: url(../../../../sort-arrow-sprite.png);
}
</style>
</head>
<body>
<div class='wrapper'>
<div class='pad1'>
<h1>
<a href="../../../../index.html">All files</a> / <a href="index.html">csv2json/libs/core/defaultParsers</a> parser_array.js
</h1>
<div class='clearfix'>
<div class='fl pad1y space-right2'>
<span class="strong">0% </span>
<span class="quiet">Statements</span>
<span class='fraction'>0/5</span>
</div>
<div class='fl pad1y space-right2'>
<span class="strong">0% </span>
<span class="quiet">Branches</span>
<span class='fraction'>0/2</span>
</div>
<div class='fl pad1y space-right2'>
<span class="strong">0% </span>
<span class="quiet">Functions</span>
<span class='fraction'>0/1</span>
</div>
<div class='fl pad1y space-right2'>
<span class="strong">0% </span>
<span class="quiet">Lines</span>
<span class='fraction'>0/5</span>
</div>
</div>
<p class="quiet">
Press <em>n</em> or <em>j</em> to go to the next uncovered block, <em>b</em>, <em>p</em> or <em>k</em> for the previous block.
</p>
</div>
<div class='status-line low'></div>
<pre><table class="coverage">
<tr><td class="line-count quiet"><a name='L1'></a><a href='#L1'>1</a>
<a name='L2'></a><a href='#L2'>2</a>
<a name='L3'></a><a href='#L3'>3</a>
<a name='L4'></a><a href='#L4'>4</a>
<a name='L5'></a><a href='#L5'>5</a>
<a name='L6'></a><a href='#L6'>6</a>
<a name='L7'></a><a href='#L7'>7</a>
<a name='L8'></a><a href='#L8'>8</a>
<a name='L9'></a><a href='#L9'>9</a>
<a name='L10'></a><a href='#L10'>10</a>
<a name='L11'></a><a href='#L11'>11</a>
<a name='L12'></a><a href='#L12'>12</a>
<a name='L13'></a><a href='#L13'>13</a></td><td class="line-coverage quiet"><span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-no">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span>
<span class="cline-any cline-neutral">&nbsp;</span></td><td class="text"><pre class="prettyprint lang-js"><span class="cstat-no" title="statement not covered" >module.exports = {</span>
"name": "array",
"processSafe":true,
"regExp": /^\*array\*/,
"parserFunc": function <span class="fstat-no" title="function not covered" >parser_array(</span>params) {
var fieldName = <span class="cstat-no" title="statement not covered" >params.head.replace(this.regExp, '');</span>
<span class="cstat-no" title="statement not covered" > if (params.resultRow[fieldName] === undefined) {</span>
<span class="cstat-no" title="statement not covered" > params.resultRow[fieldName] = [];</span>
}
<span class="cstat-no" title="statement not covered" > params.resultRow[fieldName].push(params.item);</span>
}
};
&nbsp;</pre></td></tr>
</table></pre>
<div class='push'></div><!-- for sticky footer -->
</div><!-- /wrapper -->
<div class='footer quiet pad2 space-top1 center small'>
Code coverage
generated by <a href="https://istanbul.js.org/" target="_blank">istanbul</a> at Fri May 11 2018 21:20:20 GMT+0100 (IST)
</div>
</div>
<script src="../../../../prettify.js"></script>
<script>
window.onload = function () {
if (typeof prettyPrint === 'function') {
prettyPrint();
}
};
</script>
<script src="../../../../sorter.js"></script>
<script src="../../../../block-navigation.js"></script>
</body>
</html>

View File

@@ -0,0 +1 @@
{"version":3,"file":"BestFitMatcher.d.ts","sourceRoot":"","sources":["../../../../../../../packages/intl-localematcher/abstract/BestFitMatcher.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,mBAAmB,EAAC,MAAM,SAAS,CAAA;AAG3C;;;;;GAKG;AACH,wBAAgB,cAAc,CAC5B,gBAAgB,EAAE,GAAG,CAAC,MAAM,CAAC,EAC7B,gBAAgB,EAAE,MAAM,EAAE,EAC1B,gBAAgB,EAAE,MAAM,MAAM,GAC7B,mBAAmB,CAiErB"}

View File

@@ -0,0 +1,32 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.IsWellFormedUnitIdentifier = void 0;
var IsSanctionedSimpleUnitIdentifier_1 = require("./IsSanctionedSimpleUnitIdentifier");
/**
* This follows https://tc39.es/ecma402/#sec-case-sensitivity-and-case-mapping
* @param str string to convert
*/
function toLowerCase(str) {
return str.replace(/([A-Z])/g, function (_, c) { return c.toLowerCase(); });
}
/**
* https://tc39.es/ecma402/#sec-iswellformedunitidentifier
* @param unit
*/
function IsWellFormedUnitIdentifier(unit) {
unit = toLowerCase(unit);
if ((0, IsSanctionedSimpleUnitIdentifier_1.IsSanctionedSimpleUnitIdentifier)(unit)) {
return true;
}
var units = unit.split('-per-');
if (units.length !== 2) {
return false;
}
var numerator = units[0], denominator = units[1];
if (!(0, IsSanctionedSimpleUnitIdentifier_1.IsSanctionedSimpleUnitIdentifier)(numerator) ||
!(0, IsSanctionedSimpleUnitIdentifier_1.IsSanctionedSimpleUnitIdentifier)(denominator)) {
return false;
}
return true;
}
exports.IsWellFormedUnitIdentifier = IsWellFormedUnitIdentifier;

View File

@@ -0,0 +1,21 @@
Copyright (c) 2011-2016 Heather Arthur <fayearthur@gmail.com>
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.

View File

@@ -0,0 +1,11 @@
import { ReplaySubject } from '../ReplaySubject';
import { multicast } from './multicast';
import { isFunction } from '../util/isFunction';
export function publishReplay(bufferSize, windowTime, selectorOrScheduler, timestampProvider) {
if (selectorOrScheduler && !isFunction(selectorOrScheduler)) {
timestampProvider = selectorOrScheduler;
}
const selector = isFunction(selectorOrScheduler) ? selectorOrScheduler : undefined;
return (source) => multicast(new ReplaySubject(bufferSize, windowTime, timestampProvider), selector)(source);
}
//# sourceMappingURL=publishReplay.js.map

View File

@@ -0,0 +1,5 @@
col1,col2,col3,col4,col5,col6,col7,col8,col9,col10
"Mini. Sectt,hisar S.O",125001,S.O,Non-Delivery,Hissar,Ambala HQ,Haryana,Hisar,Hisar,HARYANA
#Mini. Sectt,hisar S.O#,125001,S.O,Non-Delivery,Hissar,Ambala HQ,Haryana,Hisar,Hisar,HARYANA
#Mini. Sectt,hisar S.O#,125001,S.O,Non-Delivery,Hissar,Ambala HQ,Haryana,Hisar,Hisar,HARYANA
#Mini. Sectt,hisar S.O#,#125001,fenvkdsf#,S.O,Non-Delivery,Hissar,Ambala HQ,Haryana,Hisar,Hisar,HARYANA

View File

@@ -0,0 +1 @@
{"version":3,"file":"bindCallbackInternals.js","sourceRoot":"","sources":["../../../../src/internal/observable/bindCallbackInternals.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACnD,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAE/C,MAAM,UAAU,qBAAqB,CACnC,WAAoB,EACpB,YAAiB,EACjB,cAAoB,EACpB,SAAyB;IAEzB,IAAI,cAAc,EAAE;QAClB,IAAI,WAAW,CAAC,cAAc,CAAC,EAAE;YAC/B,SAAS,GAAG,cAAc,CAAC;SAC5B;aAAM;YAEL,OAAO;gBAAqB,cAAc;qBAAd,UAAc,EAAd,qBAAc,EAAd,IAAc;oBAAd,yBAAc;;gBACxC,OAAQ,qBAAqB,CAAC,WAAW,EAAE,YAAY,EAAE,SAAS,CAAS;qBACxE,KAAK,CAAC,IAAI,EAAE,IAAI,CAAC;qBACjB,IAAI,CAAC,gBAAgB,CAAC,cAAqB,CAAC,CAAC,CAAC;YACnD,CAAC,CAAC;SACH;KACF;IAID,IAAI,SAAS,EAAE;QACb,OAAO;YAAqB,cAAc;iBAAd,UAAc,EAAd,qBAAc,EAAd,IAAc;gBAAd,yBAAc;;YACxC,OAAQ,qBAAqB,CAAC,WAAW,EAAE,YAAY,CAAS;iBAC7D,KAAK,CAAC,IAAI,EAAE,IAAI,CAAC;iBACjB,IAAI,CAAC,WAAW,CAAC,SAAU,CAAC,EAAE,SAAS,CAAC,SAAU,CAAC,CAAC,CAAC;QAC1D,CAAC,CAAC;KACH;IAED,OAAO;QAAA,iBAgFN;QAhF2B,cAAc;aAAd,UAAc,EAAd,qBAAc,EAAd,IAAc;YAAd,yBAAc;;QAGxC,IAAM,OAAO,GAAG,IAAI,YAAY,EAAO,CAAC;QAGxC,IAAI,aAAa,GAAG,IAAI,CAAC;QACzB,OAAO,IAAI,UAAU,CAAC,UAAC,UAAU;YAE/B,IAAM,IAAI,GAAG,OAAO,CAAC,SAAS,CAAC,UAAU,CAAC,CAAC;YAE3C,IAAI,aAAa,EAAE;gBACjB,aAAa,GAAG,KAAK,CAAC;gBAMtB,IAAI,SAAO,GAAG,KAAK,CAAC;gBAGpB,IAAI,YAAU,GAAG,KAAK,CAAC;gBAKvB,YAAY,CAAC,KAAK,CAEhB,KAAI,yCAGC,IAAI;oBAEP;wBAAC,iBAAiB;6BAAjB,UAAiB,EAAjB,qBAAiB,EAAjB,IAAiB;4BAAjB,4BAAiB;;wBAChB,IAAI,WAAW,EAAE;4BAIf,IAAM,GAAG,GAAG,OAAO,CAAC,KAAK,EAAE,CAAC;4BAC5B,IAAI,GAAG,IAAI,IAAI,EAAE;gCACf,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;gCAGnB,OAAO;6BACR;yBACF;wBAKD,OAAO,CAAC,IAAI,CAAC,CAAC,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC;wBAGxD,YAAU,GAAG,IAAI,CAAC;wBAMlB,IAAI,SAAO,EAAE;4BACX,OAAO,CAAC,QAAQ,EAAE,CAAC;yBACpB;oBACH,CAAC;mBAEJ,CAAC;gBAIF,IAAI,YAAU,EAAE;oBACd,OAAO,CAAC,QAAQ,EAAE,CAAC;iBACpB;gBAID,SAAO,GAAG,IAAI,CAAC;aAChB;YAGD,OAAO,IAAI,CAAC;QACd,CAAC,CAAC,CAAC;IACL,CAAC,CAAC;AACJ,CAAC"}

View File

@@ -0,0 +1,19 @@
import { Task } from '../managers/tasks';
import Settings from '../settings';
import { MicromatchOptions, ReaderOptions } from '../types';
import DeepFilter from './filters/deep';
import EntryFilter from './filters/entry';
import ErrorFilter from './filters/error';
import EntryTransformer from './transformers/entry';
export default abstract class Provider<T> {
protected readonly _settings: Settings;
readonly errorFilter: ErrorFilter;
readonly entryFilter: EntryFilter;
readonly deepFilter: DeepFilter;
readonly entryTransformer: EntryTransformer;
constructor(_settings: Settings);
abstract read(_task: Task): T;
protected _getRootDirectory(task: Task): string;
protected _getReaderOptions(task: Task): ReaderOptions;
protected _getMicromatchOptions(): MicromatchOptions;
}

View File

@@ -0,0 +1 @@
{"version":3,"file":"FormatNumericToString.d.ts","sourceRoot":"","sources":["../../../../../../packages/ecma402-abstract/NumberFormat/FormatNumericToString.ts"],"names":[],"mappings":"AAGA,OAAO,EACL,8BAA8B,EAE/B,MAAM,iBAAiB,CAAA;AAGxB;;GAEG;AACH,wBAAgB,qBAAqB,CACnC,UAAU,EAAE,IAAI,CACd,8BAA8B,EAC5B,cAAc,GACd,0BAA0B,GAC1B,0BAA0B,GAC1B,sBAAsB,GACtB,uBAAuB,GACvB,uBAAuB,CAC1B,EACD,CAAC,EAAE,MAAM;;;EAgDV"}

View File

@@ -0,0 +1,60 @@
'use strict';
var functionsHaveNames = require('functions-have-names')();
var arrows = require('make-arrow-function').list();
var generators = require('make-generator-function')();
var asyncs = require('make-async-function').list();
var forEach = require('for-each');
var foo = Object(function foo() {});
var anon = Object(function () {});
var evalled = Object(Function()); // eslint-disable-line no-new-func
module.exports = function (getName, t) {
t.test('functions', function (st) {
if (functionsHaveNames) {
st.equal(getName(foo), foo.name, 'foo has name "foo"');
st.equal(getName(anon), anon.name, 'anonymous function has name of empty string');
st.equal(getName(evalled), evalled.name, 'eval-d function has name "anonymous" (or empty string)');
}
st.equal(getName(foo), 'foo', 'foo has name "foo"');
st.equal(getName(anon), '', 'anonymous function has name of empty string');
var evalledName = getName(evalled);
st.equal(evalledName === 'anonymous' || evalledName === '', true, 'eval-d function has name "anonymous" (or empty string');
st.end();
});
t.test('arrow functions', { skip: arrows.length === 0 }, function (st) {
st.equal(true, functionsHaveNames, 'functions have names in any env with arrow functions');
forEach(arrows, function (arrowFn) {
st.equal(getName(arrowFn), arrowFn.name, 'arrow function name matches for ' + arrowFn);
});
st.end();
});
t.test('generators', { skip: generators.length === 0 }, function (st) {
st.equal(true, functionsHaveNames, 'functions have names in any env with generator functions');
forEach(generators, function (genFn) {
st.equal(getName(genFn), genFn.name, 'generator function name matches for ' + genFn);
});
st.end();
});
t.test('asyncs', { skip: asyncs.length === 0 }, function (st) {
st.equal(true, functionsHaveNames, 'functions have names in any env with async functions');
forEach(asyncs, function (asyncFn) {
st.equal(getName(asyncFn), asyncFn.name, 'async function name matches for ' + asyncFn);
});
st.end();
});
t.test('Function.prototype.name', function (st) {
st.equal(getName(function before() {}), 'before', 'function prior to accessing Function.prototype has the right name');
var protoName = getName(Function.prototype);
// on <= node v2.5, this is "Empty" - otherwise, the empty string
st.equal(protoName === '' || protoName === 'Empty', true, 'Function.prototype has the right name');
st.equal(getName(function after() {}), 'after', 'function after accessing Function.prototype has the right name');
st.end();
});
};

View File

@@ -0,0 +1,31 @@
{
"name": "isexe",
"version": "2.0.0",
"description": "Minimal module to check if a file is executable.",
"main": "index.js",
"directories": {
"test": "test"
},
"devDependencies": {
"mkdirp": "^0.5.1",
"rimraf": "^2.5.0",
"tap": "^10.3.0"
},
"scripts": {
"test": "tap test/*.js --100",
"preversion": "npm test",
"postversion": "npm publish",
"postpublish": "git push origin --all; git push origin --tags"
},
"author": "Isaac Z. Schlueter <i@izs.me> (http://blog.izs.me/)",
"license": "ISC",
"repository": {
"type": "git",
"url": "git+https://github.com/isaacs/isexe.git"
},
"keywords": [],
"bugs": {
"url": "https://github.com/isaacs/isexe/issues"
},
"homepage": "https://github.com/isaacs/isexe#readme"
}

View File

@@ -0,0 +1 @@
module.exports={A:{A:{"1":"F A B","2":"J D E CC"},B:{"1":"C K L G M N O P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H"},C:{"1":"0 1 2 3 4 5 6 7 8 9 DC tB I v J D E F A B C K L G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB EC FC"},D:{"1":"0 1 2 3 4 5 6 7 8 9 I v J D E F A B C K L G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB GC"},E:{"1":"J D E F A B C K L G IC JC KC LC 0B qB rB 1B MC NC 2B 3B 4B 5B sB 6B 7B 8B 9B OC","2":"I HC zB","16":"v"},F:{"1":"0 1 2 3 4 5 6 7 8 9 B C G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e QC RC SC qB AC TC rB","16":"F PC"},G:{"1":"E VC WC XC YC ZC aC bC cC dC eC fC gC hC iC jC kC lC mC nC 2B 3B 4B 5B sB 6B 7B 8B 9B","16":"zB UC BC"},H:{"2":"oC"},I:{"1":"tB I f rC sC BC","16":"pC qC","132":"tC uC"},J:{"1":"D A"},K:{"1":"A B C h qB AC rB"},L:{"132":"H"},M:{"132":"H"},N:{"1":"A B"},O:{"1":"vC"},P:{"2":"I","132":"g wC xC yC zC 0C 0B 1C 2C 3C 4C 5C sB 6C 7C 8C"},Q:{"1":"1B"},R:{"132":"9C"},S:{"1":"AD BD"}},B:7,C:"KeyboardEvent.which"};

View File

@@ -0,0 +1,5 @@
import { Converter } from "./Converter";
export default function (csvRows: string[][], conv: Converter): JSONResult[];
export declare type JSONResult = {
[key: string]: any;
};

View File

@@ -0,0 +1 @@
module.exports={A:{A:{"2":"J D E F A B CC"},B:{"2":"C K L G M N O","676":"P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H"},C:{"2":"0 DC tB I v J D E F A B C K L G M N O w g x y z EC FC","804":"1 2 3 4 5 6 7 8 9 AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB"},D:{"2":"I","676":"0 1 2 3 4 5 6 7 8 9 v J D E F A B C K L G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB GC"},E:{"2":"HC zB","676":"I v J D E F A B C K L G IC JC KC LC 0B qB rB 1B MC NC 2B 3B 4B 5B sB 6B 7B 8B 9B OC"},F:{"2":"F B C PC QC RC SC qB AC TC rB","676":"0 1 2 3 4 5 6 7 8 9 G M N O w g x y z AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e"},G:{"2":"E zB UC BC VC WC XC YC ZC aC bC cC dC eC fC gC hC iC jC kC lC mC nC 2B 3B 4B 5B sB 6B 7B 8B 9B"},H:{"2":"oC"},I:{"2":"tB I f pC qC rC sC BC tC uC"},J:{"2":"D A"},K:{"2":"A B C h qB AC rB"},L:{"2":"H"},M:{"2":"H"},N:{"2":"A B"},O:{"2":"vC"},P:{"2":"I g wC xC yC zC 0C 0B 1C 2C 3C 4C 5C sB 6C 7C 8C"},Q:{"2":"1B"},R:{"2":"9C"},S:{"804":"AD BD"}},B:7,C:"CSS font-smooth"};

View File

@@ -0,0 +1,2 @@
import { Var } from '../../../../interfaces';
export default function is_dynamic(variable: Var): boolean;

View File

@@ -0,0 +1,22 @@
import { operate } from '../util/lift';
import { noop } from '../util/noop';
import { createOperatorSubscriber } from './OperatorSubscriber';
import { innerFrom } from '../observable/innerFrom';
export function buffer(closingNotifier) {
return operate(function (source, subscriber) {
var currentBuffer = [];
source.subscribe(createOperatorSubscriber(subscriber, function (value) { return currentBuffer.push(value); }, function () {
subscriber.next(currentBuffer);
subscriber.complete();
}));
innerFrom(closingNotifier).subscribe(createOperatorSubscriber(subscriber, function () {
var b = currentBuffer;
currentBuffer = [];
subscriber.next(b);
}, noop));
return function () {
currentBuffer = null;
};
});
}
//# sourceMappingURL=buffer.js.map

View File

@@ -0,0 +1,363 @@
# Release It! 🚀
🚀 Generic CLI tool to automate versioning and package publishing related tasks:
<img align="right" src="./docs/assets/release-it.svg?raw=true" height="280">
- Bump version (in e.g. `package.json`)
- [Git commit, tag, push](#git)
- Execute any (test or build) commands using [hooks](#hooks)
- [Create release at GitHub](#github-releases) or [GitLab](#gitlab-releases)
- [Generate changelog](#changelog)
- [Publish to npm](#publish-to-npm)
- [Manage pre-releases](#manage-pre-releases)
- Extend with [plugins](#plugins)
- Release from any [CI/CD environment](./docs/ci.md)
Use release-it for version management and publish to anywhere with its versatile configuration, a powerful plugin
system, and hooks to execute any command you need to test, build, and/or publish your project.
[![Action Status](https://github.com/release-it/release-it/workflows/Cross-OS%20Tests/badge.svg)](https://github.com/release-it/release-it/actions)
[![npm version](https://badge.fury.io/js/release-it.svg)](https://www.npmjs.com/package/release-it)
## Announcement
The latest major version is v15, supporting Node.js 14 and up (as Node.js v12 is EOL). Use release-it v14 for
environments running Node.js v10 and v12. Also see [CHANGELOG.md](./CHANGELOG.md).
## Links
- See [CHANGELOG.md](./CHANGELOG.md) for major/breaking updates, and
[releases](https://github.com/release-it/release-it/releases) for a detailed version history.
- To **contribute**, please read [CONTRIBUTING.md](./.github/CONTRIBUTING.md) first.
- Please [open an issue](https://github.com/release-it/release-it/issues/new) if anything is missing or unclear in this
documentation.
## Installation
Although release-it is a **generic** release tool, most projects use it for projects with npm packages. The recommended
way to install release-it uses npm and adds some minimal configuration to get started:
```bash
npm init release-it
```
Alternatively, install it manually, and add the `release` script to `package.json`:
```bash
npm install -D release-it
```
```json
{
"name": "my-package",
"version": "1.0.0",
"scripts": {
"release": "release-it"
},
"devDependencies": {
"release-it": "*"
}
}
```
Now you can run `npm run release` from the command line (put release-it arguments behind the `-- `):
```bash
npm run release
npm run release -- minor --ci
```
### Global Installation
#### Using npx or npm
Use npx to run release-it directly from anywhere:
```bash
npx release-it
```
Or use npm to install and run release-it globally:
```bash
npm install -g release-it
```
#### Using Homebrew
```bash
brew install release-it
```
## Usage
Release a new version:
```bash
release-it
```
You will be prompted to select the new version, and more prompts will follow based on your configuration.
Run release-it from the root of the project to prevent potential issues.
## Dry Runs
Use `--dry-run` to show the interactivity and the commands it _would_ execute.
→ See [Dry Runs](./docs/dry-runs.md) for more details.
To print the next version without releasing anything, add the `--release-version` flag.
To print the changelog without releasing anything, add the `--changelog` flag.
## Configuration
Out of the box, release-it has sane defaults, and [plenty of options](./config/release-it.json) to configure it. Most
projects use a `.release-it.json` in the project root, or a `release-it` property in `package.json`.
→ See [Configuration](./docs/configuration.md) for more details.
Here's a quick example `.release-it.json`:
```json
{
"git": {
"commitMessage": "chore: release v${version}"
},
"github": {
"release": true
}
}
```
## Interactive vs. CI mode
By default, release-it is **interactive** and allows you to confirm each task before execution:
<img src="./docs/assets/release-it-interactive.gif?raw=true" height="290">
By using the `--ci` option, the process is fully automated without prompts. The configured tasks will be executed as
demonstrated in the first animation above. On a Continuous Integration (CI) environment, this non-interactive mode is
activated automatically.
Use `--only-version` to use a prompt only to determine the version, and automate the rest.
## Latest version
How does release-it determine the latest version?
1. For projects with a `package.json`, its `version` will be used (see [npm](./docs/npm.md) to skip this).
2. Otherwise, release-it uses the latest Git tag to determine which version should be released.
3. As a last resort, `0.0.0` will be used as the latest version.
Alternatively, a plugin can be used to override this (e.g. to manage a `VERSION` or `composer.json` file):
- [@release-it/bumper](https://github.com/release-it/bumper) to read from or bump the version in any file
- [@release-it/conventional-changelog](https://github.com/release-it/conventional-changelog) to get a recommended bump
based on commit messages
- [release-it-calver-plugin](https://github.com/casmith/release-it-calver-plugin) to use CalVer (Calendar Versioning)
Add the `--release-version` flag to print the **next** version without releasing anything.
## Git
Git projects are supported well by release-it, automating the tasks to stage, commit, tag and push releases to any Git
remote.
→ See [Git](./docs/git.md) for more details.
## GitHub Releases
GitHub projects can have releases attached to Git tags, containing release notes and assets. There are two ways to add
[GitHub releases](https://docs.github.com/en/repositories/releasing-projects-on-github/about-releases) in your
release-it flow:
1. Automated (requires a `GITHUB_TOKEN`)
2. Manual (using the GitHub web interface with pre-populated fields)
→ See [GitHub Releases](./docs/github-releases.md) for more details.
## GitLab Releases
GitLab projects can have releases attached to Git tags, containing release notes and assets. To automate
[GitLab releases](https://docs.gitlab.com/ce/user/project/releases/):
- Configure `gitlab.release: true`
- Obtain a [personal access token](https://gitlab.com/profile/personal_access_tokens) (release-it only needs the "api"
scope).
- Make sure the token is [available as an environment variable](./docs/environment-variables.md).
→ See [GitLab Releases](./docs/gitlab-releases.md) for more details.
## Changelog
By default, release-it generates a changelog, to show and help select a version for the new release. Additionally, this
changelog serves as the release notes for the GitHub or GitLab release.
The [default command](./config/release-it.json) is based on `git log ...`. This setting (`git.changelog`) can be
overridden. To further customize the release notes for the GitHub or GitLab release, there's `github.releaseNotes` or
`gitlab.releaseNotes`. Make sure any of these commands output the changelog to `stdout`. Plugins are available for:
- GitHub and GitLab Releases
- auto-changelog
- Conventional Changelog
- Keep A Changelog
→ See [Changelog](./docs/changelog.md) for more details.
## Publish to npm
With a `package.json` in the current directory, release-it will let `npm` bump the version in `package.json` (and
`package-lock.json` if present), and publish to the npm registry.
→ See [Publish to npm](./docs/npm.md) for more details.
## Manage pre-releases
With release-it, it's easy to create pre-releases: a version of your software that you want to make available, while
it's not in the stable semver range yet. Often "alpha", "beta", and "rc" (release candidate) are used as identifier for
pre-releases. An example pre-release version is `2.0.0-beta.0`.
→ See [Manage pre-releases](./docs/pre-releases.md) for more details.
## Update or re-run existing releases
Use `--no-increment` to not increment the last version, but update the last existing tag/version.
This may be helpful in cases where the version was already incremented. Here's a few example scenarios:
- To update or publish a (draft) GitHub Release for an existing Git tag.
- Publishing to npm succeeded, but pushing the Git tag to the remote failed. Then use
`release-it --no-increment --no-npm` to skip the `npm publish` and try pushing the same Git tag again.
## Hooks
Use script hooks to run shell commands at any moment during the release process (such as `before:init` or
`after:release`).
The format is `[prefix]:[hook]` or `[prefix]:[plugin]:[hook]`:
| part | value |
| ------ | ------------------------------------------- |
| prefix | `before` or `after` |
| plugin | `version`, `git`, `npm`, `github`, `gitlab` |
| hook | `init`, `bump`, `release` |
Use the optional `:plugin` part in the middle to hook into a life cycle method exactly before or after any plugin.
The core plugins include `version`, `git`, `npm`, `github`, `gitlab`.
Note that hooks like `after:git:release` will not run when either the `git push` failed, or when it is configured not to
be executed (e.g. `git.push: false`). See [execution order](./docs/plugins.md#execution-order) for more details on
execution order of plugin lifecycle methods.
All commands can use configuration variables (like template strings). An array of commands can also be provided, they
will run one after another. Some example release-it configuration:
```json
{
"hooks": {
"before:init": ["npm run lint", "npm test"],
"after:my-plugin:bump": "./bin/my-script.sh",
"after:bump": "npm run build",
"after:git:release": "echo After git push, before github release",
"after:release": "echo Successfully released ${name} v${version} to ${repo.repository}."
}
}
```
The variables can be found in the [default configuration](./config/release-it.json). Additionally, the following
variables are exposed:
```text
version
latestVersion
changelog
name
repo.remote, repo.protocol, repo.host, repo.owner, repo.repository, repo.project
branchName
```
All variables are available in all hooks. The only exception is that the additional variables listed above are not yet
available in the `init` hook.
Use `--verbose` to log the output of the commands.
For the sake of verbosity, the full list of hooks is actually: `init`, `beforeBump`, `bump`, `beforeRelease`, `release`
or `afterRelease`. However, hooks like `before:beforeRelease` look weird and are usually not useful in practice.
Note that arguments need to be quoted properly when used from the command line:
```bash
release-it --'hooks.after:release="echo Successfully released ${name} v${version} to ${repo.repository}."'
```
Using Inquirer.js inside custom hook scripts might cause issues (since release-it also uses this itself).
## Plugins
Since v11, release-it can be extended in many, many ways. Here are some plugins:
| Plugin | Description |
| -------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------- |
| [@release-it/bumper](https://github.com/release-it/bumper) | Read & write the version from/to any file |
| [@release-it/conventional-changelog](https://github.com/release-it/conventional-changelog) | Provides recommended bump, conventional-changelog, and updates `CHANGELOG.md` |
| [@release-it/keep-a-changelog](https://github.com/release-it/keep-a-changelog) | Maintain CHANGELOG.md using the Keep a Changelog standards |
| [@release-it-plugins/lerna-changelog](https://github.com/release-it-plugins/lerna-changelog) | Integrates lerna-changelog into the release-it pipeline |
| [@release-it-plugins/workspaces](https://github.com/release-it-plugins/workspaces) | Releases each of your projects configured workspaces |
| [release-it-calver-plugin](https://github.com/casmith/release-it-calver-plugin) | Enables Calendar Versioning (calver) with release-it |
| [@grupoboticario/news-fragments](https://github.com/grupoboticario/news-fragments) | An easy way to generate your changelog file |
| [@j-ulrich/release-it-regex-bumper](https://github.com/j-ulrich/release-it-regex-bumper) | Regular expression based version read/write plugin for release-it |
Internally, release-it uses its own plugin architecture (for Git, GitHub, GitLab, npm).
→ See all [release-it plugins on npm](https://www.npmjs.com/search?q=keywords:release-it-plugin).
→ See [plugins](./docs/plugins.md) for documentation to write plugins.
## Distribution repository
Deprecated. Please see [distribution repository](./docs/recipes/distribution-repo.md) for more details.
## Metrics
In release-it v15, anonymous metrics have been removed from the codebase and no data is sent or stored anywhere.
## Troubleshooting & debugging
- With `release-it --verbose` (or `-V`), release-it prints the output of every user-defined [hook](#hooks).
- With `release-it -VV`, release-it also prints the output of every internal command.
- Use `NODE_DEBUG=release-it:* release-it [...]` to print configuration and more error details.
Use `verbose: 2` in a configuration file to have the equivalent of `-VV` on the command line.
## Use release-it programmatically
While mostly used as a CLI tool, release-it can be used as a dependency to integrate in your own scripts. See
[use release-it programmatically](./docs/recipes/programmatic.md) for example code.
## Example projects using release-it
- [axios/axios](https://github.com/axios/axios)
- [blockchain/blockchain-wallet-v4-frontend](https://github.com/blockchain/blockchain-wallet-v4-frontend)
- [callstack/react-native-paper](https://github.com/callstack/react-native-paper)
- [ember-cli/ember-cli](https://github.com/ember-cli/ember-cli)
- [js-cookie/js-cookie](https://github.com/js-cookie/js-cookie)
- [metalsmith/metalsmith](https://github.com/metalsmith/metalsmith)
- [mozilla/readability](https://github.com/mozilla/readability)
- [redis/node-redis](https://github.com/redis/node-redis)
- [saleor/saleor](https://github.com/saleor/saleor)
- [shipshapecode/shepherd](https://github.com/shipshapecode/shepherd)
- [StevenBlack/hosts](https://github.com/StevenBlack/hosts)
- [swagger-api/swagger-ui](https://github.com/swagger-api/swagger-ui) +
[swagger-editor](https://github.com/swagger-api/swagger-editor)
- [tabler/tabler](https://github.com/tabler/tabler) + [tabler-icons](https://github.com/tabler/tabler-icons)
- [youzan/vant](https://github.com/youzan/vant)
- [Repositories that depend on release-it](https://github.com/release-it/release-it/network/dependents)
- GitHub search for [filename:.release-it.json](https://github.com/search?q=filename%3A.release-it.json)
## License
[MIT](./LICENSE)

View File

@@ -0,0 +1,21 @@
The MIT License (MIT)
Copyright (c) 2015-22 Ionică Bizău <bizauionica@gmail.com> (http://ionicabizau.net)
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.

View File

@@ -0,0 +1,5 @@
var convert = require('./convert'),
func = convert('mixin', require('../mixin'));
func.placeholder = require('./placeholder');
module.exports = func;

View File

@@ -0,0 +1 @@
{"name":"crc-32","version":"1.2.2","files":{"LICENSE":{"checkedAt":1678883669142,"integrity":"sha512-A071FDW+9qnSiM4vmRwGqek0LqNK6Fq6mhVq4TTqnXIeOcWzs52FHnH58PQ4B/9vFW+K1EDklOG4x3k4Bdb31w==","mode":420,"size":11355},"crc32.js":{"checkedAt":1678883669153,"integrity":"sha512-Z8Fnz5bk7fotTducJ9H6Kk6pZzXZ8dGe6HfUhRzdArnyx0vLg6sP3jNnr081KuiilstzGyuR0ZKufR5/AxNX3A==","mode":420,"size":3566},"package.json":{"checkedAt":1678883669153,"integrity":"sha512-+nH4jFpOSz3kHpn+A97zs2TkuoLXEAPvBitxd9K57PnlTRsynbJ26P5PxrDmxXyW/RzlQI16MS9AdtrpFbe89A==","mode":420,"size":1106},"types/tsconfig.json":{"checkedAt":1678883669153,"integrity":"sha512-zz8KmwYLiz+5EY0xqfvunZbjuYfB9QyhYwYmevI47wIsu/ZqtZ+QQbRJB/wCJJ/FuCfdnnr25zsLAJdvM+B9IA==","mode":420,"size":345},"types/tslint.json":{"checkedAt":1678883669153,"integrity":"sha512-I032+3RC2qXI6qgca4YV8c921zasGQaDl5ARm9FMgsjuTZoFh2Nm1nwKJuae5r2FAtLRaKv6U+Qef9+t/Q5i8A==","mode":420,"size":261},"crc32c.js":{"checkedAt":1678883669153,"integrity":"sha512-KlyNZvX3K/Sro2qbGPnZJcI20EVOuJs4zjn0kG+NGe9FOvKcGdjBNdoQiEv29KhsrW+ZrCQLFrKB2B322rJdag==","mode":420,"size":3584},"README.md":{"checkedAt":1678883669153,"integrity":"sha512-6RvHdhdbWQyT2hZGIubj9pePfOf7XNIeOtAcSAdCC9U2wqJvIUnbaJJ8tQ+VwrqSYyxG+SEyWtZYlddyOsBKDg==","mode":420,"size":6445},"bin/crc32.njs":{"checkedAt":1678883669154,"integrity":"sha512-axKPV3oeGG4P68nOuz7mV0/jzVduUr8yzSvJ0C2zJ+InjrQoAlQAj7DqH6YrZFUzMwYdxhzI2XxfiRp4d8IrJg==","mode":493,"size":3919},"types/index.d.ts":{"checkedAt":1678883669154,"integrity":"sha512-QqkKA8oBEsrI7JppHQBl0TqtlIXhgorULPzlXMAI6+2mn4OknU2NtOHGz3ndgOZqadgNjv5eWJbO8AD1pXTwTQ==","mode":420,"size":463}}}

View File

@@ -0,0 +1 @@
module.exports={A:{A:{"2":"J D E F A CC","132":"B"},B:{"1":"C K L G M N O P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H"},C:{"1":"9 AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB","2":"0 1 2 3 4 5 6 7 8 DC tB I v J D E F A B C K L G M N O w g x y z EC FC"},D:{"1":"EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB uB ZB vB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R S T U V W X Y Z a b c d e i j k l m n o p q r s t u f H xB yB GC","2":"0 1 2 3 4 5 6 7 8 9 I v J D E F A B C K L G M N O w g x y z AB BB CB DB"},E:{"1":"D E F A B C K L G KC LC 0B qB rB 1B MC NC 2B 3B 4B 5B sB 6B 7B 8B 9B OC","2":"I v J HC zB IC","16":"JC"},F:{"1":"1 2 3 4 5 6 7 8 9 AB BB CB DB EB FB GB HB IB JB KB LB MB NB OB PB QB RB SB TB UB VB WB XB YB ZB aB bB cB dB eB fB gB hB iB jB kB h lB mB nB oB pB P Q R wB S T U V W X Y Z a b c d e","2":"0 F B C G M N O w g x y z PC QC RC SC qB AC TC rB"},G:{"1":"E YC ZC aC bC cC dC eC fC gC hC iC jC kC lC mC nC 2B 3B 4B 5B sB 6B 7B 8B 9B","2":"zB UC BC VC WC XC"},H:{"2":"oC"},I:{"1":"f tC uC","2":"tB I pC qC rC sC BC"},J:{"2":"D A"},K:{"1":"h","2":"A B C qB AC rB"},L:{"1":"H"},M:{"1":"H"},N:{"2":"A B"},O:{"1":"vC"},P:{"1":"I g wC xC yC zC 0C 0B 1C 2C 3C 4C 5C sB 6C 7C 8C"},Q:{"1":"1B"},R:{"1":"9C"},S:{"1":"AD BD"}},B:4,C:"Rebeccapurple color"};

View File

@@ -0,0 +1,2 @@
import type { Dirent, Stats } from '../types';
export declare function createDirentFromStats(name: string, stats: Stats): Dirent;

View File

@@ -0,0 +1,19 @@
"use strict";
var value = require("../../object/valid-value")
, contains = require("./contains")
, byLength = require("./_compare-by-length")
, filter = Array.prototype.filter
, push = Array.prototype.push
, slice = Array.prototype.slice;
module.exports = function (/* …list*/) {
var lists;
if (!arguments.length) slice.call(this);
push.apply((lists = [this]), arguments);
lists.forEach(value);
lists.sort(byLength);
return lists.reduce(function (list1, list2) {
return filter.call(list1, function (item) { return contains.call(list2, item); });
});
};

View File

@@ -0,0 +1,17 @@
'use strict';
var trimEnd = require('../');
var test = require('tape');
var runTests = require('./tests');
test('as a function', function (t) {
t.test('bad array/this value', function (st) {
st['throws'](function () { trimEnd(undefined, 'a'); }, TypeError, 'undefined is not an object');
st['throws'](function () { trimEnd(null, 'a'); }, TypeError, 'null is not an object');
st.end();
});
runTests(trimEnd, t);
t.end();
});

View File

@@ -0,0 +1,33 @@
module.exports = {
'camelCase': require('./camelCase'),
'capitalize': require('./capitalize'),
'deburr': require('./deburr'),
'endsWith': require('./endsWith'),
'escape': require('./escape'),
'escapeRegExp': require('./escapeRegExp'),
'kebabCase': require('./kebabCase'),
'lowerCase': require('./lowerCase'),
'lowerFirst': require('./lowerFirst'),
'pad': require('./pad'),
'padEnd': require('./padEnd'),
'padStart': require('./padStart'),
'parseInt': require('./parseInt'),
'repeat': require('./repeat'),
'replace': require('./replace'),
'snakeCase': require('./snakeCase'),
'split': require('./split'),
'startCase': require('./startCase'),
'startsWith': require('./startsWith'),
'template': require('./template'),
'templateSettings': require('./templateSettings'),
'toLower': require('./toLower'),
'toUpper': require('./toUpper'),
'trim': require('./trim'),
'trimEnd': require('./trimEnd'),
'trimStart': require('./trimStart'),
'truncate': require('./truncate'),
'unescape': require('./unescape'),
'upperCase': require('./upperCase'),
'upperFirst': require('./upperFirst'),
'words': require('./words')
};