@tsed/components-scan 7.0.0-rc.5 → 7.0.0-rc.6
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/lib/cjs/cleanGlobPatterns.js +2 -2
- package/lib/cjs/cleanGlobPatterns.js.map +1 -1
- package/lib/cjs/index.js +0 -1
- package/lib/cjs/index.js.map +1 -1
- package/lib/esm/cleanGlobPatterns.js +1 -1
- package/lib/esm/cleanGlobPatterns.js.map +1 -1
- package/lib/esm/index.js +0 -1
- package/lib/esm/index.js.map +1 -1
- package/lib/types/index.d.ts +0 -1
- package/package.json +3 -5
- package/lib/cjs/normalizePath.js +0 -19
- package/lib/cjs/normalizePath.js.map +0 -1
- package/lib/esm/normalizePath.js +0 -14
- package/lib/esm/normalizePath.js.map +0 -1
- package/lib/types/normalizePath.d.ts +0 -2
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.cleanGlobPatterns = void 0;
|
|
4
4
|
const path_1 = require("path");
|
|
5
5
|
const isTsEnv_1 = require("./isTsEnv");
|
|
6
|
-
const
|
|
6
|
+
const core_1 = require("@tsed/core");
|
|
7
7
|
function mapExcludes(excludes) {
|
|
8
8
|
return excludes.map((s) => `!${s.replace(/!/gi, "")}`);
|
|
9
9
|
}
|
|
@@ -19,7 +19,7 @@ function cleanGlobPatterns(files, excludes) {
|
|
|
19
19
|
.map((s) => (0, path_1.resolve)(s))
|
|
20
20
|
.concat(mapExcludes(excludes))
|
|
21
21
|
.map(mapExtensions)
|
|
22
|
-
.map((s) => (0,
|
|
22
|
+
.map((s) => (0, core_1.normalizePath)(s));
|
|
23
23
|
}
|
|
24
24
|
exports.cleanGlobPatterns = cleanGlobPatterns;
|
|
25
25
|
//# sourceMappingURL=cleanGlobPatterns.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cleanGlobPatterns.js","sourceRoot":"","sources":["../../src/cleanGlobPatterns.ts"],"names":[],"mappings":";;;AAAA,+BAA6B;AAC7B,uCAAkC;AAClC,
|
|
1
|
+
{"version":3,"file":"cleanGlobPatterns.js","sourceRoot":"","sources":["../../src/cleanGlobPatterns.ts"],"names":[],"mappings":";;;AAAA,+BAA6B;AAC7B,uCAAkC;AAClC,qCAAyC;AAEzC,SAAS,WAAW,CAAC,QAAkB;IACrC,OAAO,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAS,EAAE,EAAE,CAAC,IAAI,CAAC,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,EAAE,CAAC,CAAC;AACjE,CAAC;AAED,SAAS,aAAa,CAAC,IAAY;IACjC,IAAI,CAAC,IAAA,iBAAO,GAAE,EAAE;QACd,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAC,OAAO,CAAC,eAAe,EAAE,KAAK,CAAC,CAAC;KACtE;IAED,OAAO,IAAI,CAAC;AACd,CAAC;AAED,SAAgB,iBAAiB,CAAC,KAAwB,EAAE,QAAkB;IAC5E,OAAO,EAAE;SACN,MAAM,CAAC,KAAc,CAAC;SACtB,GAAG,CAAC,CAAC,CAAS,EAAE,EAAE,CAAC,IAAA,cAAO,EAAC,CAAC,CAAC,CAAC;SAC9B,MAAM,CAAC,WAAW,CAAC,QAAQ,CAAU,CAAC;SACtC,GAAG,CAAC,aAAa,CAAC;SAClB,GAAG,CAAC,CAAC,CAAS,EAAE,EAAE,CAAC,IAAA,oBAAa,EAAC,CAAC,CAAC,CAAC,CAAC;AAC1C,CAAC;AAPD,8CAOC","sourcesContent":["import {resolve} from \"path\";\nimport {isTsEnv} from \"./isTsEnv\";\nimport {normalizePath} from \"@tsed/core\";\n\nfunction mapExcludes(excludes: string[]) {\n return excludes.map((s: string) => `!${s.replace(/!/gi, \"\")}`);\n}\n\nfunction mapExtensions(file: string): string {\n if (!isTsEnv()) {\n file = file.replace(/\\.ts$/i, \".js\").replace(/{\\.ts,\\.js}$/i, \".js\");\n }\n\n return file;\n}\n\nexport function cleanGlobPatterns(files: string | string[], excludes: string[]): string[] {\n return []\n .concat(files as never)\n .map((s: string) => resolve(s))\n .concat(mapExcludes(excludes) as never)\n .map(mapExtensions)\n .map((s: string) => normalizePath(s));\n}\n"]}
|
package/lib/cjs/index.js
CHANGED
|
@@ -8,5 +8,4 @@ tslib_1.__exportStar(require("./cleanGlobPatterns"), exports);
|
|
|
8
8
|
tslib_1.__exportStar(require("./importFiles"), exports);
|
|
9
9
|
tslib_1.__exportStar(require("./importProviders"), exports);
|
|
10
10
|
tslib_1.__exportStar(require("./isTsEnv"), exports);
|
|
11
|
-
tslib_1.__exportStar(require("./normalizePath"), exports);
|
|
12
11
|
//# sourceMappingURL=index.js.map
|
package/lib/cjs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,8DAAoC;AACpC,wDAA8B;AAC9B,4DAAkC;AAClC,oDAA0B
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,8DAAoC;AACpC,wDAA8B;AAC9B,4DAAkC;AAClC,oDAA0B","sourcesContent":["/**\n * @file Automatically generated by barrelsby.\n */\n\nexport * from \"./cleanGlobPatterns\";\nexport * from \"./importFiles\";\nexport * from \"./importProviders\";\nexport * from \"./isTsEnv\";\n"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { resolve } from "path";
|
|
2
2
|
import { isTsEnv } from "./isTsEnv.js";
|
|
3
|
-
import { normalizePath } from "
|
|
3
|
+
import { normalizePath } from "@tsed/core";
|
|
4
4
|
function mapExcludes(excludes) {
|
|
5
5
|
return excludes.map((s) => `!${s.replace(/!/gi, "")}`);
|
|
6
6
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cleanGlobPatterns.js","sourceRoot":"","sources":["../../src/cleanGlobPatterns.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,OAAO,EAAC,MAAM,MAAM,CAAC;AAC7B,OAAO,EAAC,OAAO,EAAC,MAAM,WAAW,CAAC;AAClC,OAAO,EAAC,aAAa,EAAC,MAAM,
|
|
1
|
+
{"version":3,"file":"cleanGlobPatterns.js","sourceRoot":"","sources":["../../src/cleanGlobPatterns.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,OAAO,EAAC,MAAM,MAAM,CAAC;AAC7B,OAAO,EAAC,OAAO,EAAC,MAAM,WAAW,CAAC;AAClC,OAAO,EAAC,aAAa,EAAC,MAAM,YAAY,CAAC;AAEzC,SAAS,WAAW,CAAC,QAAkB;IACrC,OAAO,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAS,EAAE,EAAE,CAAC,IAAI,CAAC,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,EAAE,CAAC,CAAC;AACjE,CAAC;AAED,SAAS,aAAa,CAAC,IAAY;IACjC,IAAI,CAAC,OAAO,EAAE,EAAE;QACd,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAC,OAAO,CAAC,eAAe,EAAE,KAAK,CAAC,CAAC;KACtE;IAED,OAAO,IAAI,CAAC;AACd,CAAC;AAED,MAAM,UAAU,iBAAiB,CAAC,KAAwB,EAAE,QAAkB;IAC5E,OAAO,EAAE;SACN,MAAM,CAAC,KAAc,CAAC;SACtB,GAAG,CAAC,CAAC,CAAS,EAAE,EAAE,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;SAC9B,MAAM,CAAC,WAAW,CAAC,QAAQ,CAAU,CAAC;SACtC,GAAG,CAAC,aAAa,CAAC;SAClB,GAAG,CAAC,CAAC,CAAS,EAAE,EAAE,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,CAAC;AAC1C,CAAC","sourcesContent":["import {resolve} from \"path\";\nimport {isTsEnv} from \"./isTsEnv\";\nimport {normalizePath} from \"@tsed/core\";\n\nfunction mapExcludes(excludes: string[]) {\n return excludes.map((s: string) => `!${s.replace(/!/gi, \"\")}`);\n}\n\nfunction mapExtensions(file: string): string {\n if (!isTsEnv()) {\n file = file.replace(/\\.ts$/i, \".js\").replace(/{\\.ts,\\.js}$/i, \".js\");\n }\n\n return file;\n}\n\nexport function cleanGlobPatterns(files: string | string[], excludes: string[]): string[] {\n return []\n .concat(files as never)\n .map((s: string) => resolve(s))\n .concat(mapExcludes(excludes) as never)\n .map(mapExtensions)\n .map((s: string) => normalizePath(s));\n}\n"]}
|
package/lib/esm/index.js
CHANGED
package/lib/esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,cAAc,qBAAqB,CAAC;AACpC,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,WAAW,CAAC
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,cAAc,qBAAqB,CAAC;AACpC,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,WAAW,CAAC","sourcesContent":["/**\n * @file Automatically generated by barrelsby.\n */\n\nexport * from \"./cleanGlobPatterns\";\nexport * from \"./importFiles\";\nexport * from \"./importProviders\";\nexport * from \"./isTsEnv\";\n"]}
|
package/lib/types/index.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tsed/components-scan",
|
|
3
|
-
"version": "7.0.0-rc.
|
|
3
|
+
"version": "7.0.0-rc.6",
|
|
4
4
|
"description": "Components scan utilities for Ts.ED Framework",
|
|
5
5
|
"private": false,
|
|
6
6
|
"source": "./src/index.ts",
|
|
@@ -22,13 +22,11 @@
|
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
24
|
"globby": "11.0.3",
|
|
25
|
-
"normalize-path": "3.0.0",
|
|
26
25
|
"tslib": "2.4.0"
|
|
27
26
|
},
|
|
28
27
|
"devDependencies": {
|
|
29
|
-
"@tsed/core": "7.0.0-rc.
|
|
30
|
-
"@tsed/di": "7.0.0-rc.
|
|
31
|
-
"@types/normalize-path": "^3.0.0"
|
|
28
|
+
"@tsed/core": "7.0.0-rc.6",
|
|
29
|
+
"@tsed/di": "7.0.0-rc.6"
|
|
32
30
|
},
|
|
33
31
|
"peerDependencies": {},
|
|
34
32
|
"repository": "https://github.com/tsedio/tsed",
|
package/lib/cjs/normalizePath.js
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.normalizePath = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const core_1 = require("@tsed/core");
|
|
6
|
-
const path_1 = require("path");
|
|
7
|
-
const normalize_path_1 = tslib_1.__importDefault(require("normalize-path"));
|
|
8
|
-
function normalizePath(item, ...paths) {
|
|
9
|
-
if ((0, core_1.isString)(item)) {
|
|
10
|
-
const path = (0, path_1.join)(item, ...paths);
|
|
11
|
-
return (0, normalize_path_1.default)(path);
|
|
12
|
-
}
|
|
13
|
-
if ((0, core_1.isArray)(item)) {
|
|
14
|
-
return item.map((item) => normalizePath(item));
|
|
15
|
-
}
|
|
16
|
-
return item;
|
|
17
|
-
}
|
|
18
|
-
exports.normalizePath = normalizePath;
|
|
19
|
-
//# sourceMappingURL=normalizePath.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"normalizePath.js","sourceRoot":"","sources":["../../src/normalizePath.ts"],"names":[],"mappings":";;;;AAAA,qCAA6C;AAC7C,+BAA0B;AAC1B,4EAAqC;AAIrC,SAAgB,aAAa,CAAC,IAAS,EAAE,GAAG,KAAe;IACzD,IAAI,IAAA,eAAQ,EAAC,IAAI,CAAC,EAAE;QAClB,MAAM,IAAI,GAAG,IAAA,WAAI,EAAC,IAAI,EAAE,GAAG,KAAK,CAAC,CAAC;QAClC,OAAO,IAAA,wBAAO,EAAC,IAAI,CAAC,CAAC;KACtB;IAED,IAAI,IAAA,cAAO,EAAC,IAAI,CAAC,EAAE;QACjB,OAAO,IAAI,CAAC,GAAG,CAAC,CAAC,IAAS,EAAE,EAAE,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,CAAC;KACrD;IAED,OAAO,IAAI,CAAC;AACd,CAAC;AAXD,sCAWC","sourcesContent":["import {isArray, isString} from \"@tsed/core\";\nimport {join} from \"path\";\nimport fixPath from \"normalize-path\";\n\nexport function normalizePath(item: string, ...paths: string[]): string;\nexport function normalizePath(item: (string | any)[]): (string | any)[];\nexport function normalizePath(item: any, ...paths: string[]) {\n if (isString(item)) {\n const path = join(item, ...paths);\n return fixPath(path);\n }\n\n if (isArray(item)) {\n return item.map((item: any) => normalizePath(item));\n }\n\n return item;\n}\n"]}
|
package/lib/esm/normalizePath.js
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { isArray, isString } from "@tsed/core";
|
|
2
|
-
import { join } from "path";
|
|
3
|
-
import fixPath from "normalize-path";
|
|
4
|
-
export function normalizePath(item, ...paths) {
|
|
5
|
-
if (isString(item)) {
|
|
6
|
-
const path = join(item, ...paths);
|
|
7
|
-
return fixPath(path);
|
|
8
|
-
}
|
|
9
|
-
if (isArray(item)) {
|
|
10
|
-
return item.map((item) => normalizePath(item));
|
|
11
|
-
}
|
|
12
|
-
return item;
|
|
13
|
-
}
|
|
14
|
-
//# sourceMappingURL=normalizePath.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"normalizePath.js","sourceRoot":"","sources":["../../src/normalizePath.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,OAAO,EAAE,QAAQ,EAAC,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAC,IAAI,EAAC,MAAM,MAAM,CAAC;AAC1B,OAAO,OAAO,MAAM,gBAAgB,CAAC;AAIrC,MAAM,UAAU,aAAa,CAAC,IAAS,EAAE,GAAG,KAAe;IACzD,IAAI,QAAQ,CAAC,IAAI,CAAC,EAAE;QAClB,MAAM,IAAI,GAAG,IAAI,CAAC,IAAI,EAAE,GAAG,KAAK,CAAC,CAAC;QAClC,OAAO,OAAO,CAAC,IAAI,CAAC,CAAC;KACtB;IAED,IAAI,OAAO,CAAC,IAAI,CAAC,EAAE;QACjB,OAAO,IAAI,CAAC,GAAG,CAAC,CAAC,IAAS,EAAE,EAAE,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,CAAC;KACrD;IAED,OAAO,IAAI,CAAC;AACd,CAAC","sourcesContent":["import {isArray, isString} from \"@tsed/core\";\nimport {join} from \"path\";\nimport fixPath from \"normalize-path\";\n\nexport function normalizePath(item: string, ...paths: string[]): string;\nexport function normalizePath(item: (string | any)[]): (string | any)[];\nexport function normalizePath(item: any, ...paths: string[]) {\n if (isString(item)) {\n const path = join(item, ...paths);\n return fixPath(path);\n }\n\n if (isArray(item)) {\n return item.map((item: any) => normalizePath(item));\n }\n\n return item;\n}\n"]}
|