ddan-js 1.0.0

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.
package/CHANGELOG.md ADDED
File without changes
package/LICENSE ADDED
File without changes
package/README.md ADDED
File without changes
@@ -0,0 +1,235 @@
1
+ var toString = Object.prototype.toString;
2
+ /**
3
+ * 获取值的类型标签
4
+ * @param value - 任意值
5
+ * @returns [object Xxxx]
6
+ *
7
+ * @public
8
+ */
9
+ function getTag(value) {
10
+ if (value == null) {
11
+ return value === undefined ? "[object Undefined]" : "[object Null]";
12
+ }
13
+ return toString.call(value);
14
+ }
15
+ /**
16
+ * 判断是否是数值类型
17
+ * @param value - 任意值
18
+ * @returns true / false
19
+ * @example
20
+ * ```ts
21
+ * isNumber(2) // => true
22
+ * ```
23
+ *
24
+ * @public
25
+ */
26
+ function isNumber(value) {
27
+ return getTag(value) === "[object Number]";
28
+ }
29
+ /**
30
+ * 判断是否是字符串类型
31
+ * @param value - 任意值
32
+ * @returns true / false
33
+ * @example
34
+ * ```ts
35
+ * isString('abc') // => true
36
+ * ```
37
+ *
38
+ * @public
39
+ */
40
+ function isString(value) {
41
+ return getTag(value) === "[object String]";
42
+ }
43
+ function isChinese(content) {
44
+ if (!content) return false;
45
+ var reg = /^[\u4E00-\u9FA5]+$/;
46
+ if (!reg.test(content)) {
47
+ return false;
48
+ }
49
+ return true;
50
+ }
51
+
52
+ var is = /*#__PURE__*/Object.freeze({
53
+ __proto__: null,
54
+ getTag: getTag,
55
+ isNumber: isNumber,
56
+ isString: isString,
57
+ isChinese: isChinese
58
+ });
59
+
60
+ /******************************************************************************
61
+ Copyright (c) Microsoft Corporation.
62
+
63
+ Permission to use, copy, modify, and/or distribute this software for any
64
+ purpose with or without fee is hereby granted.
65
+
66
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
67
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
68
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
69
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
70
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
71
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
72
+ PERFORMANCE OF THIS SOFTWARE.
73
+ ***************************************************************************** */
74
+
75
+ function __spreadArray(to, from, pack) {
76
+ if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
77
+ if (ar || !(i in from)) {
78
+ if (!ar) ar = Array.prototype.slice.call(from, 0, i);
79
+ ar[i] = from[i];
80
+ }
81
+ }
82
+ return to.concat(ar || Array.prototype.slice.call(from));
83
+ }
84
+
85
+ /**
86
+ * 休眠
87
+ * @param {number} time
88
+ * @returns
89
+ */
90
+ var sleep = function sleep(time) {
91
+ if (time === void 0) {
92
+ time = 1000;
93
+ }
94
+ return new Promise(function (resolve) {
95
+ setTimeout(resolve, time);
96
+ });
97
+ };
98
+ function run(cb) {
99
+ try {
100
+ if (!cb) return null;
101
+ return cb();
102
+ } catch (err) {
103
+ return undefined;
104
+ }
105
+ }
106
+ var task = function task(promise) {
107
+ return promise.then(function (data) {
108
+ return [data, null];
109
+ })["catch"](function (err) {
110
+ return [undefined, err];
111
+ });
112
+ };
113
+ var debounce = function debounce(fn, interval) {
114
+ if (interval === void 0) {
115
+ interval = 300;
116
+ }
117
+ var timer;
118
+ var intervalTime = interval || 300;
119
+ return function func() {
120
+ var args = [];
121
+ for (var _i = 0; _i < arguments.length; _i++) {
122
+ args[_i] = arguments[_i];
123
+ }
124
+ var context = this;
125
+ if (timer) clearTimeout(timer);
126
+ timer = setTimeout(function () {
127
+ fn.call.apply(fn, __spreadArray([context], args, false));
128
+ }, intervalTime);
129
+ };
130
+ };
131
+ var throttle = function throttle(fn, delay) {
132
+ if (delay === void 0) {
133
+ delay = 300;
134
+ }
135
+ var timer;
136
+ var delayTime = delay || 300;
137
+ var lastTime = Date.now();
138
+ return function func() {
139
+ var args = [];
140
+ for (var _i = 0; _i < arguments.length; _i++) {
141
+ args[_i] = arguments[_i];
142
+ }
143
+ var context = this;
144
+ var curTime = Date.now();
145
+ var remaining = delayTime - (curTime - lastTime);
146
+ if (remaining < 0) {
147
+ timer && clearTimeout(timer);
148
+ timer = null;
149
+ fn.call.apply(fn, __spreadArray([context], args, false));
150
+ lastTime = curTime;
151
+ } else if (!timer) {
152
+ timer = setTimeout(function () {
153
+ fn.call.apply(fn, __spreadArray([context], args, false));
154
+ lastTime = Date.now();
155
+ }, delayTime);
156
+ }
157
+ };
158
+ };
159
+
160
+ var hook = /*#__PURE__*/Object.freeze({
161
+ __proto__: null,
162
+ sleep: sleep,
163
+ run: run,
164
+ task: task,
165
+ debounce: debounce,
166
+ throttle: throttle
167
+ });
168
+
169
+ /**
170
+ * 是否是今天
171
+ * @param {*} date
172
+ * @returns
173
+ */
174
+ var isToday = function isToday(date) {
175
+ return new Date().toDateString() === new Date(date).toDateString();
176
+ };
177
+ /**
178
+ * 时间格式化
179
+ * @param {string|number|Date} time
180
+ * @param {string} reg "yyyyMMdd hhmmss"
181
+ * @returns
182
+ */
183
+ var timeFormat = function timeFormat(time, reg) {
184
+ var date = typeof time === "string" || typeof time === "number" ? new Date(time) : time;
185
+ var map = {};
186
+ map.yyyy = date.getFullYear();
187
+ map.yy = "".concat(map.yyyy).substr(2);
188
+ map.M = date.getMonth() + 1;
189
+ map.MM = (map.M < 10 ? "0" : "") + map.M;
190
+ map.d = date.getDate();
191
+ map.dd = (map.d < 10 ? "0" : "") + map.d;
192
+ map.h = date.getHours();
193
+ map.hh = (map.h < 10 ? "0" : "") + map.h;
194
+ map.m = date.getMinutes();
195
+ map.mm = (map.m < 10 ? "0" : "") + map.m;
196
+ map.s = date.getSeconds();
197
+ map.ss = (map.s < 10 ? "0" : "") + map.s;
198
+ map.S = date.getMilliseconds();
199
+ map.SS = (map.S < 10 ? "0" : "") + map.S;
200
+ map.SSS = map.S.toString().padStart(3, 0);
201
+ return reg.replace(/\byyyy|yy|MM|M|dd|d|hh|h|mm|m|ss|s|SSS|SS|S\b/g, function ($1) {
202
+ return map[$1];
203
+ });
204
+ };
205
+ function parseTime(_a) {
206
+ var _b = _a.year,
207
+ year = _b === void 0 ? 0 : _b,
208
+ _c = _a.month,
209
+ month = _c === void 0 ? 0 : _c,
210
+ _d = _a.date,
211
+ date = _d === void 0 ? 0 : _d,
212
+ _e = _a.hour,
213
+ hour = _e === void 0 ? 0 : _e,
214
+ _f = _a.minute,
215
+ minute = _f === void 0 ? 0 : _f,
216
+ _g = _a.second,
217
+ second = _g === void 0 ? 0 : _g;
218
+ var format = "".concat(year || "yyyy", "/").concat(month || "MM", "/").concat(date || "dd", " ").concat(hour, ":").concat(minute, ":").concat(second);
219
+ return new Date(timeFormat(Date.now(), format)).getTime();
220
+ }
221
+
222
+ var time = /*#__PURE__*/Object.freeze({
223
+ __proto__: null,
224
+ isToday: isToday,
225
+ timeFormat: timeFormat,
226
+ parseTime: parseTime
227
+ });
228
+
229
+ var index = {
230
+ is: is,
231
+ hook: hook,
232
+ time: time
233
+ };
234
+
235
+ export { index as default };
package/lib/ddan-js.js ADDED
@@ -0,0 +1,237 @@
1
+ 'use strict';
2
+
3
+ var toString = Object.prototype.toString;
4
+ /**
5
+ * 获取值的类型标签
6
+ * @param value - 任意值
7
+ * @returns [object Xxxx]
8
+ *
9
+ * @public
10
+ */
11
+ function getTag(value) {
12
+ if (value == null) {
13
+ return value === undefined ? "[object Undefined]" : "[object Null]";
14
+ }
15
+ return toString.call(value);
16
+ }
17
+ /**
18
+ * 判断是否是数值类型
19
+ * @param value - 任意值
20
+ * @returns true / false
21
+ * @example
22
+ * ```ts
23
+ * isNumber(2) // => true
24
+ * ```
25
+ *
26
+ * @public
27
+ */
28
+ function isNumber(value) {
29
+ return getTag(value) === "[object Number]";
30
+ }
31
+ /**
32
+ * 判断是否是字符串类型
33
+ * @param value - 任意值
34
+ * @returns true / false
35
+ * @example
36
+ * ```ts
37
+ * isString('abc') // => true
38
+ * ```
39
+ *
40
+ * @public
41
+ */
42
+ function isString(value) {
43
+ return getTag(value) === "[object String]";
44
+ }
45
+ function isChinese(content) {
46
+ if (!content) return false;
47
+ var reg = /^[\u4E00-\u9FA5]+$/;
48
+ if (!reg.test(content)) {
49
+ return false;
50
+ }
51
+ return true;
52
+ }
53
+
54
+ var is = /*#__PURE__*/Object.freeze({
55
+ __proto__: null,
56
+ getTag: getTag,
57
+ isNumber: isNumber,
58
+ isString: isString,
59
+ isChinese: isChinese
60
+ });
61
+
62
+ /******************************************************************************
63
+ Copyright (c) Microsoft Corporation.
64
+
65
+ Permission to use, copy, modify, and/or distribute this software for any
66
+ purpose with or without fee is hereby granted.
67
+
68
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
69
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
70
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
71
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
72
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
73
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
74
+ PERFORMANCE OF THIS SOFTWARE.
75
+ ***************************************************************************** */
76
+
77
+ function __spreadArray(to, from, pack) {
78
+ if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
79
+ if (ar || !(i in from)) {
80
+ if (!ar) ar = Array.prototype.slice.call(from, 0, i);
81
+ ar[i] = from[i];
82
+ }
83
+ }
84
+ return to.concat(ar || Array.prototype.slice.call(from));
85
+ }
86
+
87
+ /**
88
+ * 休眠
89
+ * @param {number} time
90
+ * @returns
91
+ */
92
+ var sleep = function sleep(time) {
93
+ if (time === void 0) {
94
+ time = 1000;
95
+ }
96
+ return new Promise(function (resolve) {
97
+ setTimeout(resolve, time);
98
+ });
99
+ };
100
+ function run(cb) {
101
+ try {
102
+ if (!cb) return null;
103
+ return cb();
104
+ } catch (err) {
105
+ return undefined;
106
+ }
107
+ }
108
+ var task = function task(promise) {
109
+ return promise.then(function (data) {
110
+ return [data, null];
111
+ })["catch"](function (err) {
112
+ return [undefined, err];
113
+ });
114
+ };
115
+ var debounce = function debounce(fn, interval) {
116
+ if (interval === void 0) {
117
+ interval = 300;
118
+ }
119
+ var timer;
120
+ var intervalTime = interval || 300;
121
+ return function func() {
122
+ var args = [];
123
+ for (var _i = 0; _i < arguments.length; _i++) {
124
+ args[_i] = arguments[_i];
125
+ }
126
+ var context = this;
127
+ if (timer) clearTimeout(timer);
128
+ timer = setTimeout(function () {
129
+ fn.call.apply(fn, __spreadArray([context], args, false));
130
+ }, intervalTime);
131
+ };
132
+ };
133
+ var throttle = function throttle(fn, delay) {
134
+ if (delay === void 0) {
135
+ delay = 300;
136
+ }
137
+ var timer;
138
+ var delayTime = delay || 300;
139
+ var lastTime = Date.now();
140
+ return function func() {
141
+ var args = [];
142
+ for (var _i = 0; _i < arguments.length; _i++) {
143
+ args[_i] = arguments[_i];
144
+ }
145
+ var context = this;
146
+ var curTime = Date.now();
147
+ var remaining = delayTime - (curTime - lastTime);
148
+ if (remaining < 0) {
149
+ timer && clearTimeout(timer);
150
+ timer = null;
151
+ fn.call.apply(fn, __spreadArray([context], args, false));
152
+ lastTime = curTime;
153
+ } else if (!timer) {
154
+ timer = setTimeout(function () {
155
+ fn.call.apply(fn, __spreadArray([context], args, false));
156
+ lastTime = Date.now();
157
+ }, delayTime);
158
+ }
159
+ };
160
+ };
161
+
162
+ var hook = /*#__PURE__*/Object.freeze({
163
+ __proto__: null,
164
+ sleep: sleep,
165
+ run: run,
166
+ task: task,
167
+ debounce: debounce,
168
+ throttle: throttle
169
+ });
170
+
171
+ /**
172
+ * 是否是今天
173
+ * @param {*} date
174
+ * @returns
175
+ */
176
+ var isToday = function isToday(date) {
177
+ return new Date().toDateString() === new Date(date).toDateString();
178
+ };
179
+ /**
180
+ * 时间格式化
181
+ * @param {string|number|Date} time
182
+ * @param {string} reg "yyyyMMdd hhmmss"
183
+ * @returns
184
+ */
185
+ var timeFormat = function timeFormat(time, reg) {
186
+ var date = typeof time === "string" || typeof time === "number" ? new Date(time) : time;
187
+ var map = {};
188
+ map.yyyy = date.getFullYear();
189
+ map.yy = "".concat(map.yyyy).substr(2);
190
+ map.M = date.getMonth() + 1;
191
+ map.MM = (map.M < 10 ? "0" : "") + map.M;
192
+ map.d = date.getDate();
193
+ map.dd = (map.d < 10 ? "0" : "") + map.d;
194
+ map.h = date.getHours();
195
+ map.hh = (map.h < 10 ? "0" : "") + map.h;
196
+ map.m = date.getMinutes();
197
+ map.mm = (map.m < 10 ? "0" : "") + map.m;
198
+ map.s = date.getSeconds();
199
+ map.ss = (map.s < 10 ? "0" : "") + map.s;
200
+ map.S = date.getMilliseconds();
201
+ map.SS = (map.S < 10 ? "0" : "") + map.S;
202
+ map.SSS = map.S.toString().padStart(3, 0);
203
+ return reg.replace(/\byyyy|yy|MM|M|dd|d|hh|h|mm|m|ss|s|SSS|SS|S\b/g, function ($1) {
204
+ return map[$1];
205
+ });
206
+ };
207
+ function parseTime(_a) {
208
+ var _b = _a.year,
209
+ year = _b === void 0 ? 0 : _b,
210
+ _c = _a.month,
211
+ month = _c === void 0 ? 0 : _c,
212
+ _d = _a.date,
213
+ date = _d === void 0 ? 0 : _d,
214
+ _e = _a.hour,
215
+ hour = _e === void 0 ? 0 : _e,
216
+ _f = _a.minute,
217
+ minute = _f === void 0 ? 0 : _f,
218
+ _g = _a.second,
219
+ second = _g === void 0 ? 0 : _g;
220
+ var format = "".concat(year || "yyyy", "/").concat(month || "MM", "/").concat(date || "dd", " ").concat(hour, ":").concat(minute, ":").concat(second);
221
+ return new Date(timeFormat(Date.now(), format)).getTime();
222
+ }
223
+
224
+ var time = /*#__PURE__*/Object.freeze({
225
+ __proto__: null,
226
+ isToday: isToday,
227
+ timeFormat: timeFormat,
228
+ parseTime: parseTime
229
+ });
230
+
231
+ var index = {
232
+ is: is,
233
+ hook: hook,
234
+ time: time
235
+ };
236
+
237
+ module.exports = index;
package/lib/index.d.ts ADDED
@@ -0,0 +1,111 @@
1
+ declare const debounce: (fn: Function, interval?: number) => (...args: any[]) => void;
2
+
3
+ declare const _default: {
4
+ is: typeof is;
5
+ hook: typeof hook;
6
+ time: typeof time;
7
+ };
8
+ export default _default;
9
+
10
+ /**
11
+ * 获取值的类型标签
12
+ * @param value - 任意值
13
+ * @returns [object Xxxx]
14
+ *
15
+ * @public
16
+ */
17
+ declare function getTag(value: any): string;
18
+
19
+ declare namespace hook {
20
+ export {
21
+ run,
22
+ sleep,
23
+ task,
24
+ debounce,
25
+ throttle
26
+ }
27
+ }
28
+
29
+ declare namespace is {
30
+ export {
31
+ getTag,
32
+ isNumber,
33
+ isString,
34
+ isChinese
35
+ }
36
+ }
37
+
38
+ declare function isChinese(content: string): boolean;
39
+
40
+ /**
41
+ * 判断是否是数值类型
42
+ * @param value - 任意值
43
+ * @returns true / false
44
+ * @example
45
+ * ```ts
46
+ * isNumber(2) // => true
47
+ * ```
48
+ *
49
+ * @public
50
+ */
51
+ declare function isNumber(value: any): boolean;
52
+
53
+ /**
54
+ * 判断是否是字符串类型
55
+ * @param value - 任意值
56
+ * @returns true / false
57
+ * @example
58
+ * ```ts
59
+ * isString('abc') // => true
60
+ * ```
61
+ *
62
+ * @public
63
+ */
64
+ declare function isString(value: any): boolean;
65
+
66
+ /**
67
+ * 是否是今天
68
+ * @param {*} date
69
+ * @returns
70
+ */
71
+ declare const isToday: (date: any) => boolean;
72
+
73
+ declare function parseTime({ year, month, date, hour, minute, second }: {
74
+ year?: number | undefined;
75
+ month?: number | undefined;
76
+ date?: number | undefined;
77
+ hour?: number | undefined;
78
+ minute?: number | undefined;
79
+ second?: number | undefined;
80
+ }): number;
81
+
82
+ declare function run(cb: Function): any;
83
+
84
+ /**
85
+ * 休眠
86
+ * @param {number} time
87
+ * @returns
88
+ */
89
+ declare const sleep: (time?: number) => Promise<unknown>;
90
+
91
+ declare const task: (promise: Promise<any>) => Promise<any[]>;
92
+
93
+ declare const throttle: (fn: Function, delay?: number) => (...args: any[]) => void;
94
+
95
+ declare namespace time {
96
+ export {
97
+ parseTime,
98
+ isToday,
99
+ timeFormat
100
+ }
101
+ }
102
+
103
+ /**
104
+ * 时间格式化
105
+ * @param {string|number|Date} time
106
+ * @param {string} reg "yyyyMMdd hhmmss"
107
+ * @returns
108
+ */
109
+ declare const timeFormat: (time: string | number | Date, reg: string) => string;
110
+
111
+ export { }
@@ -0,0 +1,12 @@
1
+ /**
2
+ *
3
+ * @param str
4
+ * @returns
5
+ */
6
+ export declare function gbkLength(str: string): number;
7
+ /**
8
+ * 根据gbk字符长度截取内容
9
+ * @param {string} source
10
+ * @param {number} len
11
+ */
12
+ export declare function gbkCut(source: string, len: number): string;
@@ -0,0 +1,10 @@
1
+ /**
2
+ * 休眠
3
+ * @param {number} time
4
+ * @returns
5
+ */
6
+ export declare const sleep: (time?: number) => Promise<unknown>;
7
+ export declare function run(cb: Function): any;
8
+ export declare const task: (promise: Promise<any>) => Promise<any[]>;
9
+ export declare const debounce: (fn: Function, interval?: number) => (...args: any[]) => void;
10
+ export declare const throttle: (fn: Function, delay?: number) => (...args: any[]) => void;
@@ -0,0 +1,21 @@
1
+ /**
2
+ * 是否是今天
3
+ * @param {*} date
4
+ * @returns
5
+ */
6
+ export declare const isToday: (date: any) => boolean;
7
+ /**
8
+ * 时间格式化
9
+ * @param {string|number|Date} time
10
+ * @param {string} reg "yyyyMMdd hhmmss"
11
+ * @returns
12
+ */
13
+ export declare const timeFormat: (time: string | number | Date, reg: string) => string;
14
+ export declare function parseTime({ year, month, date, hour, minute, second }: {
15
+ year?: number | undefined;
16
+ month?: number | undefined;
17
+ date?: number | undefined;
18
+ hour?: number | undefined;
19
+ minute?: number | undefined;
20
+ second?: number | undefined;
21
+ }): number;
@@ -0,0 +1,11 @@
1
+ // This file is read by tools that parse documentation comments conforming to the TSDoc standard.
2
+ // It should be published with your NPM package. It should not be tracked by Git.
3
+ {
4
+ "tsdocVersion": "0.12",
5
+ "toolPackages": [
6
+ {
7
+ "packageName": "@microsoft/api-extractor",
8
+ "packageVersion": "7.34.4"
9
+ }
10
+ ]
11
+ }
package/package.json ADDED
@@ -0,0 +1,82 @@
1
+ {
2
+ "name": "ddan-js",
3
+ "version": "1.0.0",
4
+ "description": "工具库",
5
+ "main": "lib/ddan-js.js",
6
+ "module": "lib/ddan-js.esm.js",
7
+ "typings": "lib/ddan-js.d.ts",
8
+ "files": [
9
+ "lib",
10
+ "LICENSE",
11
+ "CHANGELOG.md",
12
+ "README.md"
13
+ ],
14
+ "sideEffects": "false",
15
+ "repository": {
16
+ "type": "git",
17
+ "url": "git+https://github.com/yry2580/ddan-js.git"
18
+ },
19
+ "author": "Simon",
20
+ "license": "MIT",
21
+ "bugs": {
22
+ "url": "https://github.com/yry2580/ddan-js/issues"
23
+ },
24
+ "publishConfig": {
25
+ "access": "public",
26
+ "registry": "https://registry.npmjs.org/"
27
+ },
28
+ "homepage": "https://github.com/yry2580/ddan-js#readme",
29
+ "scripts": {
30
+ "build": "gulp build",
31
+ "api": "api-extractor run",
32
+ "test": "jest --coverage --verbose -u",
33
+ "test:watch": "jest --coverage --verbose --watch",
34
+ "lint": "eslint --ext .js,.ts --format=pretty ./src",
35
+ "lint:fix": "eslint --fix --ext .js,.ts --format=pretty ./src",
36
+ "changelog": "gulp changelog",
37
+ "version": "yarn changelog && git add CHANGELOG.md",
38
+ "release": "yarn test && yarn build && np --no-cleanup --yolo --any-branch",
39
+ "prepare": "husky install"
40
+ },
41
+ "devDependencies": {
42
+ "@babel/core": "^7.17.9",
43
+ "@babel/plugin-transform-runtime": "^7.17.0",
44
+ "@babel/preset-env": "^7.16.11",
45
+ "@babel/preset-typescript": "^7.16.7",
46
+ "@microsoft/api-extractor": "^7.23.0",
47
+ "@rollup/plugin-babel": "^5.3.1",
48
+ "@rollup/plugin-commonjs": "^22.0.0",
49
+ "@rollup/plugin-json": "^4.1.0",
50
+ "@rollup/plugin-node-resolve": "^13.2.1",
51
+ "@rollup/plugin-typescript": "^8.3.2",
52
+ "@types/fs-extra": "^9.0.13",
53
+ "@types/gulp": "^4.0.9",
54
+ "@types/inquirer": "^9.0.3",
55
+ "@types/jest": "^27.4.1",
56
+ "@types/node": "^17.0.25",
57
+ "@yueqing/lint": "^2.2.0",
58
+ "chalk": "^4.1.2",
59
+ "conventional-changelog": "^3.1.25",
60
+ "fs-extra": "^10.1.0",
61
+ "gulp": "^4.0.2",
62
+ "husky": "^7.0.4",
63
+ "jest": "^27.5.1",
64
+ "lint-staged": "^12.4.0",
65
+ "np": "^7.6.1",
66
+ "rollup": "^2.79.1",
67
+ "rollup-plugin-terser": "^7.0.2",
68
+ "rollup-plugin-typescript2": "^0.34.1",
69
+ "ts-jest": "^27.1.4",
70
+ "ts-node": "^10.7.0",
71
+ "tslib": "^2.4.0",
72
+ "typescript": "^4.9.5"
73
+ },
74
+ "dependencies": {
75
+ "@babel/runtime": "^7.17.9"
76
+ },
77
+ "lint-staged": {
78
+ "*.{ts,js}": [
79
+ "eslint --fix --format=pretty"
80
+ ]
81
+ }
82
+ }