@alterior/common 3.9.1 → 3.13.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (162) hide show
  1. package/dist/base64.d.ts +6 -6
  2. package/dist/base64.js +52 -52
  3. package/dist/base64.js.map +1 -1
  4. package/dist/base64.test.d.ts +1 -1
  5. package/dist/cache.d.ts +84 -84
  6. package/dist/cache.js +148 -148
  7. package/dist/cache.js.map +1 -1
  8. package/dist/cache.test.d.ts +1 -1
  9. package/dist/check-native-async.d.ts +1 -1
  10. package/dist/check-native-async.js +27 -28
  11. package/dist/check-native-async.js.map +1 -1
  12. package/dist/clone.d.ts +23 -23
  13. package/dist/clone.js +59 -60
  14. package/dist/clone.js.map +1 -1
  15. package/dist/clone.test.d.ts +1 -1
  16. package/dist/coalesce.d.ts +5 -5
  17. package/dist/coalesce.js +15 -16
  18. package/dist/coalesce.js.map +1 -1
  19. package/dist/coalesce.test.d.ts +1 -1
  20. package/dist/colors.d.ts +62 -62
  21. package/dist/colors.js +66 -66
  22. package/dist/console.d.ts +31 -31
  23. package/dist/console.d.ts.map +1 -1
  24. package/dist/console.js +65 -86
  25. package/dist/console.js.map +1 -1
  26. package/dist/constructor.d.ts +6 -6
  27. package/dist/constructor.js +2 -2
  28. package/dist/decorators.d.ts +1 -1
  29. package/dist/decorators.d.ts.map +1 -1
  30. package/dist/decorators.js +6 -7
  31. package/dist/decorators.js.map +1 -1
  32. package/dist/environment.d.ts +11 -11
  33. package/dist/environment.d.ts.map +1 -1
  34. package/dist/environment.js +27 -27
  35. package/dist/environment.js.map +1 -1
  36. package/dist/errors.d.ts +66 -66
  37. package/dist/errors.js +133 -133
  38. package/dist/errors.test.d.ts +1 -1
  39. package/dist/get-param-names.d.ts +5 -5
  40. package/dist/get-param-names.js +48 -49
  41. package/dist/get-param-names.js.map +1 -1
  42. package/dist/index.d.ts +20 -20
  43. package/dist/index.js +23 -23
  44. package/dist/is-constructor.d.ts +12 -12
  45. package/dist/is-constructor.js +28 -29
  46. package/dist/is-constructor.js.map +1 -1
  47. package/dist/is-constructor.test.d.ts +1 -1
  48. package/dist/lazy-promise.d.ts +14 -14
  49. package/dist/lazy-promise.js +32 -32
  50. package/dist/lazy-promise.js.map +1 -1
  51. package/dist/lazy-subject.d.ts +22 -22
  52. package/dist/lazy-subject.js +22 -23
  53. package/dist/lazy-subject.js.map +1 -1
  54. package/dist/locks.d.ts +23 -23
  55. package/dist/locks.js +76 -76
  56. package/dist/locks.js.map +1 -1
  57. package/dist/locks.test.d.ts +1 -1
  58. package/dist/locks.test.js.map +1 -1
  59. package/dist/padding.d.ts +22 -22
  60. package/dist/padding.js +42 -43
  61. package/dist/padding.js.map +1 -1
  62. package/dist/presentation.d.ts +49 -49
  63. package/dist/presentation.d.ts.map +1 -1
  64. package/dist/presentation.js +132 -132
  65. package/dist/presentation.js.map +1 -1
  66. package/dist/presentation.test.d.ts +1 -1
  67. package/dist/presentation.test.js.map +1 -1
  68. package/dist/serializer.d.ts +8 -8
  69. package/dist/serializer.js +23 -24
  70. package/dist/serializer.js.map +1 -1
  71. package/dist/test.d.ts +2 -2
  72. package/dist/time.d.ts +9 -9
  73. package/dist/time.js +22 -22
  74. package/dist/time.js.map +1 -1
  75. package/dist/timeout.d.ts +13 -13
  76. package/dist/timeout.js +27 -28
  77. package/dist/timeout.js.map +1 -1
  78. package/dist/zones.d.ts +46 -46
  79. package/dist/zones.js +139 -139
  80. package/dist/zones.js.map +1 -1
  81. package/dist.esm/base64.d.ts +6 -6
  82. package/dist.esm/base64.js +48 -48
  83. package/dist.esm/base64.js.map +1 -1
  84. package/dist.esm/base64.test.d.ts +1 -1
  85. package/dist.esm/cache.d.ts +84 -84
  86. package/dist.esm/cache.js +144 -144
  87. package/dist.esm/cache.js.map +1 -1
  88. package/dist.esm/cache.test.d.ts +1 -1
  89. package/dist.esm/check-native-async.d.ts +1 -1
  90. package/dist.esm/check-native-async.js +24 -24
  91. package/dist.esm/check-native-async.js.map +1 -1
  92. package/dist.esm/clone.d.ts +23 -23
  93. package/dist.esm/clone.js +53 -53
  94. package/dist.esm/clone.js.map +1 -1
  95. package/dist.esm/clone.test.d.ts +1 -1
  96. package/dist.esm/coalesce.d.ts +5 -5
  97. package/dist.esm/coalesce.js +12 -12
  98. package/dist.esm/coalesce.js.map +1 -1
  99. package/dist.esm/coalesce.test.d.ts +1 -1
  100. package/dist.esm/colors.d.ts +62 -62
  101. package/dist.esm/colors.js +63 -63
  102. package/dist.esm/console.d.ts +31 -31
  103. package/dist.esm/console.d.ts.map +1 -1
  104. package/dist.esm/console.js +60 -80
  105. package/dist.esm/console.js.map +1 -1
  106. package/dist.esm/constructor.d.ts +6 -6
  107. package/dist.esm/constructor.js +1 -1
  108. package/dist.esm/decorators.d.ts +1 -1
  109. package/dist.esm/decorators.d.ts.map +1 -1
  110. package/dist.esm/decorators.js +3 -3
  111. package/dist.esm/environment.d.ts +11 -11
  112. package/dist.esm/environment.d.ts.map +1 -1
  113. package/dist.esm/environment.js +24 -24
  114. package/dist.esm/environment.js.map +1 -1
  115. package/dist.esm/errors.d.ts +66 -66
  116. package/dist.esm/errors.js +115 -115
  117. package/dist.esm/errors.test.d.ts +1 -1
  118. package/dist.esm/get-param-names.d.ts +5 -5
  119. package/dist.esm/get-param-names.js +45 -45
  120. package/dist.esm/get-param-names.js.map +1 -1
  121. package/dist.esm/index.d.ts +20 -20
  122. package/dist.esm/index.js +20 -20
  123. package/dist.esm/is-constructor.d.ts +12 -12
  124. package/dist.esm/is-constructor.js +24 -24
  125. package/dist.esm/is-constructor.js.map +1 -1
  126. package/dist.esm/is-constructor.test.d.ts +1 -1
  127. package/dist.esm/lazy-promise.d.ts +14 -14
  128. package/dist.esm/lazy-promise.js +28 -28
  129. package/dist.esm/lazy-promise.js.map +1 -1
  130. package/dist.esm/lazy-subject.d.ts +22 -22
  131. package/dist.esm/lazy-subject.js +19 -19
  132. package/dist.esm/locks.d.ts +23 -23
  133. package/dist.esm/locks.js +71 -71
  134. package/dist.esm/locks.js.map +1 -1
  135. package/dist.esm/locks.test.d.ts +1 -1
  136. package/dist.esm/locks.test.js.map +1 -1
  137. package/dist.esm/padding.d.ts +22 -22
  138. package/dist.esm/padding.js +37 -37
  139. package/dist.esm/presentation.d.ts +49 -49
  140. package/dist.esm/presentation.d.ts.map +1 -1
  141. package/dist.esm/presentation.js +126 -126
  142. package/dist.esm/presentation.js.map +1 -1
  143. package/dist.esm/presentation.test.d.ts +1 -1
  144. package/dist.esm/presentation.test.js.map +1 -1
  145. package/dist.esm/serializer.d.ts +8 -8
  146. package/dist.esm/serializer.js +20 -20
  147. package/dist.esm/test.d.ts +2 -2
  148. package/dist.esm/time.d.ts +9 -9
  149. package/dist.esm/time.js +19 -19
  150. package/dist.esm/time.js.map +1 -1
  151. package/dist.esm/timeout.d.ts +13 -13
  152. package/dist.esm/timeout.js +23 -23
  153. package/dist.esm/tsconfig.esm.tsbuildinfo +1 -0
  154. package/dist.esm/zones.d.ts +46 -46
  155. package/dist.esm/zones.js +135 -135
  156. package/dist.esm/zones.js.map +1 -1
  157. package/package.json +11 -8
  158. package/src/console.ts +2 -22
  159. package/src/environment.ts +2 -0
  160. package/tsconfig.esm.json +0 -3
  161. package/tsconfig.json +0 -2
  162. package/tsconfig.tsbuildinfo +1 -3791
package/dist/errors.js CHANGED
@@ -1,134 +1,134 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.HttpError = exports.AccessDeniedError = exports.InvalidOperationError = exports.FormatError = exports.IOError = exports.TimeoutError = exports.OperationCanceledError = exports.NotImplementedError = exports.NotSupportedError = exports.ArgumentOutOfRangeError = exports.ArgumentNullError = exports.ArgumentError = exports.ApplicationError = exports.SystemError = exports.BaseError = void 0;
4
- class BaseError extends Error {
5
- constructor(message, options) {
6
- super(message, options);
7
- }
8
- static setJSONSerializer(serializer) {
9
- this.serializer = serializer;
10
- }
11
- asJSON() {
12
- if (BaseError.serializer)
13
- return BaseError.serializer(this);
14
- let ownKeys = Object.getOwnPropertyNames(this);
15
- let repr = {
16
- $type: this.constructor.name,
17
- error: true,
18
- message: this.message,
19
- stack: this['stack']
20
- };
21
- let includedData = ownKeys
22
- .filter(x => !x.startsWith('_'))
23
- .filter(x => typeof this[x] !== 'function')
24
- .map(x => [x, this[x]])
25
- .reduce((pv, cv) => pv[cv[0]] = cv[1], {});
26
- return Object.assign({}, repr, includedData);
27
- }
28
- }
29
- exports.BaseError = BaseError;
30
- /**
31
- * Base class for errors thrown by the system or framework
32
- */
33
- class SystemError extends BaseError {
34
- }
35
- exports.SystemError = SystemError;
36
- /**
37
- * Base class for errors thrown by your application
38
- */
39
- class ApplicationError extends BaseError {
40
- }
41
- exports.ApplicationError = ApplicationError;
42
- class ArgumentError extends SystemError {
43
- constructor(argumentName, message) {
44
- super(message || `Invalid value for argument ${argumentName}`);
45
- this._argumentName = argumentName;
46
- }
47
- /**
48
- * The invalid value passed for the given argument
49
- */
50
- get value() {
51
- return this._value;
52
- }
53
- withValue(value) {
54
- this._value = value;
55
- return this;
56
- }
57
- /**
58
- * The name of the argument
59
- */
60
- get argumentName() {
61
- return this._argumentName;
62
- }
63
- }
64
- exports.ArgumentError = ArgumentError;
65
- class ArgumentNullError extends ArgumentError {
66
- constructor(argumentName, message) {
67
- super(argumentName, message || `Argument ${argumentName} cannot be null`);
68
- }
69
- }
70
- exports.ArgumentNullError = ArgumentNullError;
71
- class ArgumentOutOfRangeError extends ArgumentError {
72
- constructor(argumentName, message) {
73
- super(argumentName, message || `Argument ${argumentName} is out of range`);
74
- }
75
- }
76
- exports.ArgumentOutOfRangeError = ArgumentOutOfRangeError;
77
- class NotSupportedError extends SystemError {
78
- constructor(message) {
79
- super(message || `The requested operation is not supported.`);
80
- }
81
- }
82
- exports.NotSupportedError = NotSupportedError;
83
- class NotImplementedError extends SystemError {
84
- constructor(message) {
85
- super(message || `The requested operation is not implemented.`);
86
- }
87
- }
88
- exports.NotImplementedError = NotImplementedError;
89
- class OperationCanceledError extends SystemError {
90
- constructor(message) {
91
- super(message || `The requested operation is not implemented.`);
92
- }
93
- }
94
- exports.OperationCanceledError = OperationCanceledError;
95
- class TimeoutError extends SystemError {
96
- constructor(message) {
97
- super(message || `The operation has timed out.`);
98
- }
99
- }
100
- exports.TimeoutError = TimeoutError;
101
- class IOError extends SystemError {
102
- constructor(message) {
103
- super(message || `An I/O error has occurred.`);
104
- }
105
- }
106
- exports.IOError = IOError;
107
- class FormatError extends SystemError {
108
- constructor(message) {
109
- super(message || `Invalid format.`);
110
- }
111
- }
112
- exports.FormatError = FormatError;
113
- class InvalidOperationError extends SystemError {
114
- constructor(message) {
115
- super(message || `Invalid format.`);
116
- }
117
- }
118
- exports.InvalidOperationError = InvalidOperationError;
119
- class AccessDeniedError extends SystemError {
120
- constructor(message) {
121
- super(message || `Invalid format.`);
122
- }
123
- }
124
- exports.AccessDeniedError = AccessDeniedError;
125
- class HttpError extends Error {
126
- constructor(statusCode, body, headers = []) {
127
- super(`HttpError statusCode=${statusCode} [are you sure you meant to catch this?]`);
128
- this.statusCode = statusCode;
129
- this.body = body;
130
- this.headers = headers;
131
- }
132
- }
133
- exports.HttpError = HttpError;
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.HttpError = exports.AccessDeniedError = exports.InvalidOperationError = exports.FormatError = exports.IOError = exports.TimeoutError = exports.OperationCanceledError = exports.NotImplementedError = exports.NotSupportedError = exports.ArgumentOutOfRangeError = exports.ArgumentNullError = exports.ArgumentError = exports.ApplicationError = exports.SystemError = exports.BaseError = void 0;
4
+ class BaseError extends Error {
5
+ constructor(message, options) {
6
+ super(message, options);
7
+ }
8
+ static setJSONSerializer(serializer) {
9
+ this.serializer = serializer;
10
+ }
11
+ asJSON() {
12
+ if (BaseError.serializer)
13
+ return BaseError.serializer(this);
14
+ let ownKeys = Object.getOwnPropertyNames(this);
15
+ let repr = {
16
+ $type: this.constructor.name,
17
+ error: true,
18
+ message: this.message,
19
+ stack: this['stack']
20
+ };
21
+ let includedData = ownKeys
22
+ .filter(x => !x.startsWith('_'))
23
+ .filter(x => typeof this[x] !== 'function')
24
+ .map(x => [x, this[x]])
25
+ .reduce((pv, cv) => pv[cv[0]] = cv[1], {});
26
+ return Object.assign({}, repr, includedData);
27
+ }
28
+ }
29
+ exports.BaseError = BaseError;
30
+ /**
31
+ * Base class for errors thrown by the system or framework
32
+ */
33
+ class SystemError extends BaseError {
34
+ }
35
+ exports.SystemError = SystemError;
36
+ /**
37
+ * Base class for errors thrown by your application
38
+ */
39
+ class ApplicationError extends BaseError {
40
+ }
41
+ exports.ApplicationError = ApplicationError;
42
+ class ArgumentError extends SystemError {
43
+ constructor(argumentName, message) {
44
+ super(message || `Invalid value for argument ${argumentName}`);
45
+ this._argumentName = argumentName;
46
+ }
47
+ /**
48
+ * The invalid value passed for the given argument
49
+ */
50
+ get value() {
51
+ return this._value;
52
+ }
53
+ withValue(value) {
54
+ this._value = value;
55
+ return this;
56
+ }
57
+ /**
58
+ * The name of the argument
59
+ */
60
+ get argumentName() {
61
+ return this._argumentName;
62
+ }
63
+ }
64
+ exports.ArgumentError = ArgumentError;
65
+ class ArgumentNullError extends ArgumentError {
66
+ constructor(argumentName, message) {
67
+ super(argumentName, message || `Argument ${argumentName} cannot be null`);
68
+ }
69
+ }
70
+ exports.ArgumentNullError = ArgumentNullError;
71
+ class ArgumentOutOfRangeError extends ArgumentError {
72
+ constructor(argumentName, message) {
73
+ super(argumentName, message || `Argument ${argumentName} is out of range`);
74
+ }
75
+ }
76
+ exports.ArgumentOutOfRangeError = ArgumentOutOfRangeError;
77
+ class NotSupportedError extends SystemError {
78
+ constructor(message) {
79
+ super(message || `The requested operation is not supported.`);
80
+ }
81
+ }
82
+ exports.NotSupportedError = NotSupportedError;
83
+ class NotImplementedError extends SystemError {
84
+ constructor(message) {
85
+ super(message || `The requested operation is not implemented.`);
86
+ }
87
+ }
88
+ exports.NotImplementedError = NotImplementedError;
89
+ class OperationCanceledError extends SystemError {
90
+ constructor(message) {
91
+ super(message || `The requested operation is not implemented.`);
92
+ }
93
+ }
94
+ exports.OperationCanceledError = OperationCanceledError;
95
+ class TimeoutError extends SystemError {
96
+ constructor(message) {
97
+ super(message || `The operation has timed out.`);
98
+ }
99
+ }
100
+ exports.TimeoutError = TimeoutError;
101
+ class IOError extends SystemError {
102
+ constructor(message) {
103
+ super(message || `An I/O error has occurred.`);
104
+ }
105
+ }
106
+ exports.IOError = IOError;
107
+ class FormatError extends SystemError {
108
+ constructor(message) {
109
+ super(message || `Invalid format.`);
110
+ }
111
+ }
112
+ exports.FormatError = FormatError;
113
+ class InvalidOperationError extends SystemError {
114
+ constructor(message) {
115
+ super(message || `Invalid format.`);
116
+ }
117
+ }
118
+ exports.InvalidOperationError = InvalidOperationError;
119
+ class AccessDeniedError extends SystemError {
120
+ constructor(message) {
121
+ super(message || `Invalid format.`);
122
+ }
123
+ }
124
+ exports.AccessDeniedError = AccessDeniedError;
125
+ class HttpError extends Error {
126
+ constructor(statusCode, body, headers = []) {
127
+ super(`HttpError statusCode=${statusCode} [are you sure you meant to catch this?]`);
128
+ this.statusCode = statusCode;
129
+ this.body = body;
130
+ this.headers = headers;
131
+ }
132
+ }
133
+ exports.HttpError = HttpError;
134
134
  //# sourceMappingURL=errors.js.map
@@ -1,2 +1,2 @@
1
- export {};
1
+ export {};
2
2
  //# sourceMappingURL=errors.test.d.ts.map
@@ -1,6 +1,6 @@
1
- /**
2
- * Get the names of the parameters of the given function.
3
- * @param fn
4
- */
5
- export declare function getParameterNames(fn: Function): string[];
1
+ /**
2
+ * Get the names of the parameters of the given function.
3
+ * @param fn
4
+ */
5
+ export declare function getParameterNames(fn: Function): string[];
6
6
  //# sourceMappingURL=get-param-names.d.ts.map
@@ -1,50 +1,49 @@
1
- "use strict";
2
- // Originally from https://github.com/goatslacker/get-parameter-names
3
- Object.defineProperty(exports, "__esModule", { value: true });
4
- exports.getParameterNames = void 0;
5
- /**
6
- * @hidden
7
- */
8
- let COMMENTS = /((\/\/.*$)|(\/\*[\s\S]*?\*\/))/mg;
9
- /**
10
- * @hidden
11
- */
12
- let DEFAULT_PARAMS = /=[^,)]+/mg;
13
- /**
14
- * @hidden
15
- */
16
- let FAT_ARROWS = /=>.*$/mg;
17
- /**
18
- * @hidden
19
- */
20
- let SPACES = /\s/mg;
21
- /**
22
- * @hidden
23
- */
24
- let BEFORE_OPENING_PAREN = /^[^(]*\(/mg;
25
- /**
26
- * @hidden
27
- */
28
- let AFTER_CLOSING_PAREN = /^([^)]*)\).*$/mg;
29
- /**
30
- * Get the names of the parameters of the given function.
31
- * @param fn
32
- */
33
- function getParameterNames(fn) {
34
- // Sometimes the user may want to transform or replace a function, which may cause us to lose access to
35
- // the parameter names. To provide an escape hatch for that use case, we'll check if the given function
36
- // has been annotated with parameter names already.
37
- if ('__parameterNames' in fn) {
38
- return fn['__parameterNames'];
39
- }
40
- let code = fn.toString()
41
- .replace(SPACES, '')
42
- .replace(COMMENTS, '')
43
- .replace(FAT_ARROWS, '')
44
- .replace(DEFAULT_PARAMS, '')
45
- .replace(BEFORE_OPENING_PAREN, '')
46
- .replace(AFTER_CLOSING_PAREN, '$1');
47
- return code ? code.split(',') : [];
48
- }
49
- exports.getParameterNames = getParameterNames;
1
+ "use strict";
2
+ // Originally from https://github.com/goatslacker/get-parameter-names
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.getParameterNames = getParameterNames;
5
+ /**
6
+ * @hidden
7
+ */
8
+ let COMMENTS = /((\/\/.*$)|(\/\*[\s\S]*?\*\/))/mg;
9
+ /**
10
+ * @hidden
11
+ */
12
+ let DEFAULT_PARAMS = /=[^,)]+/mg;
13
+ /**
14
+ * @hidden
15
+ */
16
+ let FAT_ARROWS = /=>.*$/mg;
17
+ /**
18
+ * @hidden
19
+ */
20
+ let SPACES = /\s/mg;
21
+ /**
22
+ * @hidden
23
+ */
24
+ let BEFORE_OPENING_PAREN = /^[^(]*\(/mg;
25
+ /**
26
+ * @hidden
27
+ */
28
+ let AFTER_CLOSING_PAREN = /^([^)]*)\).*$/mg;
29
+ /**
30
+ * Get the names of the parameters of the given function.
31
+ * @param fn
32
+ */
33
+ function getParameterNames(fn) {
34
+ // Sometimes the user may want to transform or replace a function, which may cause us to lose access to
35
+ // the parameter names. To provide an escape hatch for that use case, we'll check if the given function
36
+ // has been annotated with parameter names already.
37
+ if ('__parameterNames' in fn) {
38
+ return fn['__parameterNames'];
39
+ }
40
+ let code = fn.toString()
41
+ .replace(SPACES, '')
42
+ .replace(COMMENTS, '')
43
+ .replace(FAT_ARROWS, '')
44
+ .replace(DEFAULT_PARAMS, '')
45
+ .replace(BEFORE_OPENING_PAREN, '')
46
+ .replace(AFTER_CLOSING_PAREN, '$1');
47
+ return code ? code.split(',') : [];
48
+ }
50
49
  //# sourceMappingURL=get-param-names.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"get-param-names.js","sourceRoot":"","sources":["../src/get-param-names.ts"],"names":[],"mappings":";AAAA,qEAAqE;;;AAErE;;GAEG;AACH,IAAI,QAAQ,GAAG,kCAAkC,CAAC;AAClD;;GAEG;AACH,IAAI,cAAc,GAAG,WAAW,CAAC;AACjC;;GAEG;AACH,IAAI,UAAU,GAAG,SAAS,CAAC;AAC3B;;GAEG;AACH,IAAI,MAAM,GAAG,MAAM,CAAC;AACpB;;GAEG;AACH,IAAI,oBAAoB,GAAG,YAAY,CAAC;AACtC;;GAEG;AACL,IAAI,mBAAmB,GAAG,iBAAiB,CAAC;AAE5C;;;GAGG;AACH,SAAgB,iBAAiB,CAAC,EAAY;IAE5C,wGAAwG;IACxG,uGAAuG;IACvG,mDAAmD;IAEnD,IAAI,kBAAkB,IAAI,EAAE,EAAE;QAC5B,OAAO,EAAE,CAAC,kBAAkB,CAAa,CAAC;KAC3C;IAED,IAAI,IAAI,GAAG,EAAE,CAAC,QAAQ,EAAE;SACrB,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC;SACnB,OAAO,CAAC,QAAQ,EAAE,EAAE,CAAC;SACrB,OAAO,CAAC,UAAU,EAAE,EAAE,CAAC;SACvB,OAAO,CAAC,cAAc,EAAE,EAAE,CAAC;SAC3B,OAAO,CAAC,oBAAoB,EAAE,EAAE,CAAC;SACjC,OAAO,CAAC,mBAAmB,EAAE,IAAI,CAAC,CAAC;IAEtC,OAAO,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;AACrC,CAAC;AAnBD,8CAmBC"}
1
+ {"version":3,"file":"get-param-names.js","sourceRoot":"","sources":["../src/get-param-names.ts"],"names":[],"mappings":";AAAA,qEAAqE;;AA+BrE,8CAmBC;AAhDD;;GAEG;AACH,IAAI,QAAQ,GAAG,kCAAkC,CAAC;AAClD;;GAEG;AACH,IAAI,cAAc,GAAG,WAAW,CAAC;AACjC;;GAEG;AACH,IAAI,UAAU,GAAG,SAAS,CAAC;AAC3B;;GAEG;AACH,IAAI,MAAM,GAAG,MAAM,CAAC;AACpB;;GAEG;AACH,IAAI,oBAAoB,GAAG,YAAY,CAAC;AACtC;;GAEG;AACL,IAAI,mBAAmB,GAAG,iBAAiB,CAAC;AAE5C;;;GAGG;AACH,SAAgB,iBAAiB,CAAC,EAAY;IAE5C,wGAAwG;IACxG,uGAAuG;IACvG,mDAAmD;IAEnD,IAAI,kBAAkB,IAAI,EAAE,EAAE,CAAC;QAC7B,OAAO,EAAE,CAAC,kBAAkB,CAAa,CAAC;IAC5C,CAAC;IAED,IAAI,IAAI,GAAG,EAAE,CAAC,QAAQ,EAAE;SACrB,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC;SACnB,OAAO,CAAC,QAAQ,EAAE,EAAE,CAAC;SACrB,OAAO,CAAC,UAAU,EAAE,EAAE,CAAC;SACvB,OAAO,CAAC,cAAc,EAAE,EAAE,CAAC;SAC3B,OAAO,CAAC,oBAAoB,EAAE,EAAE,CAAC;SACjC,OAAO,CAAC,mBAAmB,EAAE,IAAI,CAAC,CAAC;IAEtC,OAAO,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;AACrC,CAAC"}
package/dist/index.d.ts CHANGED
@@ -1,21 +1,21 @@
1
- export * from './zones';
2
- export * from './clone';
3
- export * from './coalesce';
4
- export * from './colors';
5
- export * from './console';
6
- export * from './environment';
7
- export * from './errors';
8
- export * from './timeout';
9
- export * from './base64';
10
- export * from './cache';
11
- export * from './serializer';
12
- export * from './lazy-promise';
13
- export * from './locks';
14
- export * from './presentation';
15
- export * from './time';
16
- export * from './get-param-names';
17
- export * from './lazy-subject';
18
- export * from './check-native-async';
19
- export * from './is-constructor';
20
- export * from './padding';
1
+ export * from './zones';
2
+ export * from './clone';
3
+ export * from './coalesce';
4
+ export * from './colors';
5
+ export * from './console';
6
+ export * from './environment';
7
+ export * from './errors';
8
+ export * from './timeout';
9
+ export * from './base64';
10
+ export * from './cache';
11
+ export * from './serializer';
12
+ export * from './lazy-promise';
13
+ export * from './locks';
14
+ export * from './presentation';
15
+ export * from './time';
16
+ export * from './get-param-names';
17
+ export * from './lazy-subject';
18
+ export * from './check-native-async';
19
+ export * from './is-constructor';
20
+ export * from './padding';
21
21
  //# sourceMappingURL=index.d.ts.map
package/dist/index.js CHANGED
@@ -1,24 +1,24 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- tslib_1.__exportStar(require("./zones"), exports);
5
- tslib_1.__exportStar(require("./clone"), exports);
6
- tslib_1.__exportStar(require("./coalesce"), exports);
7
- tslib_1.__exportStar(require("./colors"), exports);
8
- tslib_1.__exportStar(require("./console"), exports);
9
- tslib_1.__exportStar(require("./environment"), exports);
10
- tslib_1.__exportStar(require("./errors"), exports);
11
- tslib_1.__exportStar(require("./timeout"), exports);
12
- tslib_1.__exportStar(require("./base64"), exports);
13
- tslib_1.__exportStar(require("./cache"), exports);
14
- tslib_1.__exportStar(require("./serializer"), exports);
15
- tslib_1.__exportStar(require("./lazy-promise"), exports);
16
- tslib_1.__exportStar(require("./locks"), exports);
17
- tslib_1.__exportStar(require("./presentation"), exports);
18
- tslib_1.__exportStar(require("./time"), exports);
19
- tslib_1.__exportStar(require("./get-param-names"), exports);
20
- tslib_1.__exportStar(require("./lazy-subject"), exports);
21
- tslib_1.__exportStar(require("./check-native-async"), exports);
22
- tslib_1.__exportStar(require("./is-constructor"), exports);
23
- tslib_1.__exportStar(require("./padding"), exports);
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const tslib_1 = require("tslib");
4
+ tslib_1.__exportStar(require("./zones"), exports);
5
+ tslib_1.__exportStar(require("./clone"), exports);
6
+ tslib_1.__exportStar(require("./coalesce"), exports);
7
+ tslib_1.__exportStar(require("./colors"), exports);
8
+ tslib_1.__exportStar(require("./console"), exports);
9
+ tslib_1.__exportStar(require("./environment"), exports);
10
+ tslib_1.__exportStar(require("./errors"), exports);
11
+ tslib_1.__exportStar(require("./timeout"), exports);
12
+ tslib_1.__exportStar(require("./base64"), exports);
13
+ tslib_1.__exportStar(require("./cache"), exports);
14
+ tslib_1.__exportStar(require("./serializer"), exports);
15
+ tslib_1.__exportStar(require("./lazy-promise"), exports);
16
+ tslib_1.__exportStar(require("./locks"), exports);
17
+ tslib_1.__exportStar(require("./presentation"), exports);
18
+ tslib_1.__exportStar(require("./time"), exports);
19
+ tslib_1.__exportStar(require("./get-param-names"), exports);
20
+ tslib_1.__exportStar(require("./lazy-subject"), exports);
21
+ tslib_1.__exportStar(require("./check-native-async"), exports);
22
+ tslib_1.__exportStar(require("./is-constructor"), exports);
23
+ tslib_1.__exportStar(require("./padding"), exports);
24
24
  //# sourceMappingURL=index.js.map
@@ -1,13 +1,13 @@
1
- /**
2
- * Check if the given function is constructable. Note that this is not the same as a *class*. In Ecmascript, normal
3
- * functions are also constructable. Use isClass() if you want to check if a function is a class.
4
- *
5
- * @see https://stackoverflow.com/a/46759625
6
- */
7
- export declare function isConstructor(f: Function): boolean;
8
- /**
9
- * Check if the given function is a class. Note that this only works for Ecmascript standard classes, the older
10
- * prototype style constructor functions will return false here.
11
- */
12
- export declare function isClass(f: Function): boolean;
1
+ /**
2
+ * Check if the given function is constructable. Note that this is not the same as a *class*. In Ecmascript, normal
3
+ * functions are also constructable. Use isClass() if you want to check if a function is a class.
4
+ *
5
+ * @see https://stackoverflow.com/a/46759625
6
+ */
7
+ export declare function isConstructor(f: Function): boolean;
8
+ /**
9
+ * Check if the given function is a class. Note that this only works for Ecmascript standard classes, the older
10
+ * prototype style constructor functions will return false here.
11
+ */
12
+ export declare function isClass(f: Function): boolean;
13
13
  //# sourceMappingURL=is-constructor.d.ts.map
@@ -1,30 +1,29 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isClass = exports.isConstructor = void 0;
4
- /**
5
- * Check if the given function is constructable. Note that this is not the same as a *class*. In Ecmascript, normal
6
- * functions are also constructable. Use isClass() if you want to check if a function is a class.
7
- *
8
- * @see https://stackoverflow.com/a/46759625
9
- */
10
- function isConstructor(f) {
11
- if (f === Symbol)
12
- return false;
13
- try {
14
- Reflect.construct(String, [], f);
15
- }
16
- catch (e) {
17
- return false;
18
- }
19
- return true;
20
- }
21
- exports.isConstructor = isConstructor;
22
- /**
23
- * Check if the given function is a class. Note that this only works for Ecmascript standard classes, the older
24
- * prototype style constructor functions will return false here.
25
- */
26
- function isClass(f) {
27
- return f.toString().startsWith('class ');
28
- }
29
- exports.isClass = isClass;
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.isConstructor = isConstructor;
4
+ exports.isClass = isClass;
5
+ /**
6
+ * Check if the given function is constructable. Note that this is not the same as a *class*. In Ecmascript, normal
7
+ * functions are also constructable. Use isClass() if you want to check if a function is a class.
8
+ *
9
+ * @see https://stackoverflow.com/a/46759625
10
+ */
11
+ function isConstructor(f) {
12
+ if (f === Symbol)
13
+ return false;
14
+ try {
15
+ Reflect.construct(String, [], f);
16
+ }
17
+ catch (e) {
18
+ return false;
19
+ }
20
+ return true;
21
+ }
22
+ /**
23
+ * Check if the given function is a class. Note that this only works for Ecmascript standard classes, the older
24
+ * prototype style constructor functions will return false here.
25
+ */
26
+ function isClass(f) {
27
+ return f.toString().startsWith('class ');
28
+ }
30
29
  //# sourceMappingURL=is-constructor.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"is-constructor.js","sourceRoot":"","sources":["../src/is-constructor.ts"],"names":[],"mappings":";;;AAAA;;;;;GAKG;AACH,SAAgB,aAAa,CAAC,CAAW;IACrC,IAAI,CAAC,KAAK,MAAM;QACZ,OAAO,KAAK,CAAC;IAEjB,IAAI;QACA,OAAO,CAAC,SAAS,CAAC,MAAM,EAAE,EAAE,EAAE,CAAC,CAAC,CAAC;KACpC;IAAC,OAAO,CAAC,EAAE;QACR,OAAO,KAAK,CAAC;KAChB;IACD,OAAO,IAAI,CAAC;AAChB,CAAC;AAVD,sCAUC;AAED;;;GAGG;AACH,SAAgB,OAAO,CAAC,CAAW;IAC/B,OAAO,CAAC,CAAC,QAAQ,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,CAAC;AAC7C,CAAC;AAFD,0BAEC"}
1
+ {"version":3,"file":"is-constructor.js","sourceRoot":"","sources":["../src/is-constructor.ts"],"names":[],"mappings":";;AAMA,sCAUC;AAMD,0BAEC;AAxBD;;;;;GAKG;AACH,SAAgB,aAAa,CAAC,CAAW;IACrC,IAAI,CAAC,KAAK,MAAM;QACZ,OAAO,KAAK,CAAC;IAEjB,IAAI,CAAC;QACD,OAAO,CAAC,SAAS,CAAC,MAAM,EAAE,EAAE,EAAE,CAAC,CAAC,CAAC;IACrC,CAAC;IAAC,OAAO,CAAC,EAAE,CAAC;QACT,OAAO,KAAK,CAAC;IACjB,CAAC;IACD,OAAO,IAAI,CAAC;AAChB,CAAC;AAED;;;GAGG;AACH,SAAgB,OAAO,CAAC,CAAW;IAC/B,OAAO,CAAC,CAAC,QAAQ,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,CAAC;AAC7C,CAAC"}
@@ -1,2 +1,2 @@
1
- export {};
1
+ export {};
2
2
  //# sourceMappingURL=is-constructor.test.d.ts.map
@@ -1,15 +1,15 @@
1
- /**
2
- * A promise that lets you wait until someone actually requests the result of the promise to kick off
3
- * the action being promised. This lets you return the promise before you start executing the async action.
4
- */
5
- export declare class LazyPromise<T> extends Promise<T> {
6
- private fulfiller;
7
- constructor(fulfiller: () => Promise<T>);
8
- private _resolve;
9
- private _reject;
10
- fulfill(): void;
11
- private realPromise;
12
- then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): Promise<TResult1 | TResult2>;
13
- catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): Promise<T | TResult>;
14
- }
1
+ /**
2
+ * A promise that lets you wait until someone actually requests the result of the promise to kick off
3
+ * the action being promised. This lets you return the promise before you start executing the async action.
4
+ */
5
+ export declare class LazyPromise<T> extends Promise<T> {
6
+ private fulfiller;
7
+ constructor(fulfiller: () => Promise<T>);
8
+ private _resolve;
9
+ private _reject;
10
+ fulfill(): void;
11
+ private realPromise;
12
+ then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): Promise<TResult1 | TResult2>;
13
+ catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): Promise<T | TResult>;
14
+ }
15
15
  //# sourceMappingURL=lazy-promise.d.ts.map