@teambit/component-issues 0.0.137 → 0.0.138
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/circular-dependencies.ts +11 -0
- package/component-issue.ts +75 -0
- package/dist/circular-dependencies.js +12 -26
- package/dist/circular-dependencies.js.map +1 -1
- package/dist/component-issue.js +57 -79
- package/dist/component-issue.js.map +1 -1
- package/dist/duplicate-component-and-package.js +12 -26
- package/dist/duplicate-component-and-package.js.map +1 -1
- package/dist/external-env-without-version.js +15 -29
- package/dist/external-env-without-version.js.map +1 -1
- package/dist/import-non-main-files.js +10 -23
- package/dist/import-non-main-files.js.map +1 -1
- package/dist/index.js +10 -81
- package/dist/index.js.map +1 -1
- package/dist/issues-list.js +131 -263
- package/dist/issues-list.js.map +1 -1
- package/dist/legacy-inside-harmony.js +12 -26
- package/dist/legacy-inside-harmony.js.map +1 -1
- package/dist/merge-config-has-conflict.js +12 -26
- package/dist/merge-config-has-conflict.js.map +1 -1
- package/dist/missing-dependencies-on-fs.js +9 -22
- package/dist/missing-dependencies-on-fs.js.map +1 -1
- package/dist/missing-dists.js +12 -26
- package/dist/missing-dists.js.map +1 -1
- package/dist/missing-links-from-nm-to-src.js +12 -26
- package/dist/missing-links-from-nm-to-src.js.map +1 -1
- package/dist/missing-manually-configured-packages.js +12 -26
- package/dist/missing-manually-configured-packages.js.map +1 -1
- package/dist/missing-packages-dependencies-on-fs.js +14 -25
- package/dist/missing-packages-dependencies-on-fs.js.map +1 -1
- package/dist/multiple-envs.js +12 -27
- package/dist/multiple-envs.js.map +1 -1
- package/dist/non-loaded-env.js +12 -26
- package/dist/non-loaded-env.js.map +1 -1
- package/dist/parse-errors.js +9 -22
- package/dist/parse-errors.js.map +1 -1
- package/dist/relative-components-authored.js +36 -55
- package/dist/relative-components-authored.js.map +1 -1
- package/dist/relative-components.js +13 -26
- package/dist/relative-components.js.map +1 -1
- package/dist/removed-dependencies.js +12 -27
- package/dist/removed-dependencies.js.map +1 -1
- package/dist/resolve-errors.js +9 -22
- package/dist/resolve-errors.js.map +1 -1
- package/dist/tsconfig.json +32 -0
- package/dist/untracked-dependencies.js +32 -47
- package/dist/untracked-dependencies.js.map +1 -1
- package/duplicate-component-and-package.ts +11 -0
- package/external-env-without-version.ts +19 -0
- package/import-non-main-files.ts +8 -0
- package/index.ts +5 -0
- package/issues-list.ts +162 -0
- package/legacy-inside-harmony.ts +11 -0
- package/merge-config-has-conflict.ts +11 -0
- package/missing-dependencies-on-fs.ts +7 -0
- package/missing-dists.ts +11 -0
- package/missing-links-from-nm-to-src.ts +11 -0
- package/missing-manually-configured-packages.ts +10 -0
- package/missing-packages-dependencies-on-fs.ts +18 -0
- package/multiple-envs.ts +12 -0
- package/non-loaded-env.ts +11 -0
- package/package.json +7 -39
- package/parse-errors.ts +7 -0
- package/relative-components-authored.ts +49 -0
- package/relative-components.ts +12 -0
- package/removed-dependencies.ts +11 -0
- package/resolve-errors.ts +7 -0
- package/tsconfig.json +2 -11
- package/untracked-dependencies.ts +41 -0
- /package/dist/{preview-1703505948637.js → preview-1703647408454.js} +0 -0
package/dist/missing-dists.js
CHANGED
|
@@ -1,31 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.MissingDists = void 0;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
constructor(...args) {
|
|
19
|
-
super(...args);
|
|
20
|
-
_defineProperty(this, "description", 'missing dists');
|
|
21
|
-
_defineProperty(this, "solution", 'run "bit compile"');
|
|
22
|
-
_defineProperty(this, "data", void 0);
|
|
23
|
-
_defineProperty(this, "isTagBlocker", false);
|
|
24
|
-
}
|
|
25
|
-
outputForCLI() {
|
|
26
|
-
return (0, _componentIssue().formatTitle)(this.descriptionWithSolution, false);
|
|
27
|
-
}
|
|
4
|
+
const component_issue_1 = require("./component-issue");
|
|
5
|
+
class MissingDists extends component_issue_1.ComponentIssue {
|
|
6
|
+
constructor() {
|
|
7
|
+
super(...arguments);
|
|
8
|
+
this.description = 'missing dists';
|
|
9
|
+
this.solution = 'run "bit compile"';
|
|
10
|
+
this.isTagBlocker = false;
|
|
11
|
+
}
|
|
12
|
+
outputForCLI() {
|
|
13
|
+
return (0, component_issue_1.formatTitle)(this.descriptionWithSolution, false);
|
|
14
|
+
}
|
|
28
15
|
}
|
|
29
16
|
exports.MissingDists = MissingDists;
|
|
30
|
-
|
|
31
17
|
//# sourceMappingURL=missing-dists.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"missing-dists.js","sourceRoot":"","sources":["../missing-dists.ts"],"names":[],"mappings":";;;AAAA,uDAAgE;AAEhE,MAAa,YAAa,SAAQ,gCAAc;IAAhD;;QACE,gBAAW,GAAG,eAAe,CAAC;QAC9B,aAAQ,GAAG,mBAAmB,CAAC;QAE/B,iBAAY,GAAG,KAAK,CAAC;IAIvB,CAAC;IAHC,YAAY;QACV,OAAO,IAAA,6BAAW,EAAC,IAAI,CAAC,uBAAuB,EAAE,KAAK,CAAC,CAAC;IAC1D,CAAC;CACF;AARD,oCAQC"}
|
|
@@ -1,31 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.MissingLinksFromNodeModulesToSrc = void 0;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
constructor(...args) {
|
|
19
|
-
super(...args);
|
|
20
|
-
_defineProperty(this, "description", 'missing links from node_modules to source');
|
|
21
|
-
_defineProperty(this, "solution", 'run "bit link"');
|
|
22
|
-
_defineProperty(this, "data", void 0);
|
|
23
|
-
_defineProperty(this, "isTagBlocker", false);
|
|
24
|
-
}
|
|
25
|
-
outputForCLI() {
|
|
26
|
-
return (0, _componentIssue().formatTitle)(this.descriptionWithSolution, false);
|
|
27
|
-
}
|
|
4
|
+
const component_issue_1 = require("./component-issue");
|
|
5
|
+
class MissingLinksFromNodeModulesToSrc extends component_issue_1.ComponentIssue {
|
|
6
|
+
constructor() {
|
|
7
|
+
super(...arguments);
|
|
8
|
+
this.description = 'missing links from node_modules to source';
|
|
9
|
+
this.solution = 'run "bit link"';
|
|
10
|
+
this.isTagBlocker = false;
|
|
11
|
+
}
|
|
12
|
+
outputForCLI() {
|
|
13
|
+
return (0, component_issue_1.formatTitle)(this.descriptionWithSolution, false);
|
|
14
|
+
}
|
|
28
15
|
}
|
|
29
16
|
exports.MissingLinksFromNodeModulesToSrc = MissingLinksFromNodeModulesToSrc;
|
|
30
|
-
|
|
31
17
|
//# sourceMappingURL=missing-links-from-nm-to-src.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"missing-links-from-nm-to-src.js","sourceRoot":"","sources":["../missing-links-from-nm-to-src.ts"],"names":[],"mappings":";;;AAAA,uDAAgE;AAEhE,MAAa,gCAAiC,SAAQ,gCAAc;IAApE;;QACE,gBAAW,GAAG,2CAA2C,CAAC;QAC1D,aAAQ,GAAG,gBAAgB,CAAC;QAE5B,iBAAY,GAAG,KAAK,CAAC;IAIvB,CAAC;IAHC,YAAY;QACV,OAAO,IAAA,6BAAW,EAAC,IAAI,CAAC,uBAAuB,EAAE,KAAK,CAAC,CAAC;IAC1D,CAAC;CACF;AARD,4EAQC"}
|
|
@@ -1,31 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.MissingManuallyConfiguredPackages = void 0;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
constructor(...args) {
|
|
19
|
-
super(...args);
|
|
20
|
-
_defineProperty(this, "description", `missing packages that were manually set`);
|
|
21
|
-
_defineProperty(this, "solution", `run "bit install"`);
|
|
22
|
-
_defineProperty(this, "data", []);
|
|
23
|
-
}
|
|
24
|
-
// package names
|
|
25
|
-
dataToString() {
|
|
26
|
-
return _componentIssue().ISSUE_FORMAT_SPACE + this.data.join(', ');
|
|
27
|
-
}
|
|
4
|
+
const component_issue_1 = require("./component-issue");
|
|
5
|
+
class MissingManuallyConfiguredPackages extends component_issue_1.ComponentIssue {
|
|
6
|
+
constructor() {
|
|
7
|
+
super(...arguments);
|
|
8
|
+
this.description = `missing packages that were manually set`;
|
|
9
|
+
this.solution = `run "bit install"`;
|
|
10
|
+
this.data = []; // package names
|
|
11
|
+
}
|
|
12
|
+
dataToString() {
|
|
13
|
+
return component_issue_1.ISSUE_FORMAT_SPACE + this.data.join(', ');
|
|
14
|
+
}
|
|
28
15
|
}
|
|
29
16
|
exports.MissingManuallyConfiguredPackages = MissingManuallyConfiguredPackages;
|
|
30
|
-
|
|
31
17
|
//# sourceMappingURL=missing-manually-configured-packages.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"missing-manually-configured-packages.js","sourceRoot":"","sources":["../missing-manually-configured-packages.ts"],"names":[],"mappings":";;;AAAA,uDAAuE;AAEvE,MAAa,iCAAkC,SAAQ,gCAAc;IAArE;;QACE,gBAAW,GAAG,yCAAyC,CAAC;QACxD,aAAQ,GAAG,mBAAmB,CAAC;QAC/B,SAAI,GAAa,EAAE,CAAC,CAAC,gBAAgB;IAIvC,CAAC;IAHC,YAAY;QACV,OAAO,oCAAkB,GAAG,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACnD,CAAC;CACF;AAPD,8EAOC"}
|
|
@@ -1,30 +1,19 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.MissingPackagesDependenciesOnFs = void 0;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
_defineProperty(this, "description", `missing packages or links from node_modules to the source`);
|
|
21
|
-
_defineProperty(this, "solution", `run "bit install --add-missing-deps" to fix both issues`);
|
|
22
|
-
_defineProperty(this, "data", []);
|
|
23
|
-
}
|
|
24
|
-
dataToString() {
|
|
25
|
-
return this.data.map(d => `${_componentIssue().ISSUE_FORMAT_SPACE}${d.filePath} -> ${this.formatDataFunction(d.missingPackages)}`).join('\n');
|
|
26
|
-
}
|
|
4
|
+
const component_issue_1 = require("./component-issue");
|
|
5
|
+
class MissingPackagesDependenciesOnFs extends component_issue_1.ComponentIssue {
|
|
6
|
+
constructor() {
|
|
7
|
+
super(...arguments);
|
|
8
|
+
this.description = `missing packages or links from node_modules to the source`;
|
|
9
|
+
this.solution = `run "bit install --add-missing-deps" to fix both issues`;
|
|
10
|
+
this.data = [];
|
|
11
|
+
}
|
|
12
|
+
dataToString() {
|
|
13
|
+
return this.data
|
|
14
|
+
.map((d) => `${component_issue_1.ISSUE_FORMAT_SPACE}${d.filePath} -> ${this.formatDataFunction(d.missingPackages)}`)
|
|
15
|
+
.join('\n');
|
|
16
|
+
}
|
|
27
17
|
}
|
|
28
18
|
exports.MissingPackagesDependenciesOnFs = MissingPackagesDependenciesOnFs;
|
|
29
|
-
|
|
30
19
|
//# sourceMappingURL=missing-packages-dependencies-on-fs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"missing-packages-dependencies-on-fs.js","sourceRoot":"","sources":["../missing-packages-dependencies-on-fs.ts"],"names":[],"mappings":";;;AAAA,uDAAuE;AAQvE,MAAa,+BAAgC,SAAQ,gCAAc;IAAnE;;QACE,gBAAW,GAAG,2DAA2D,CAAC;QAC1E,aAAQ,GAAG,yDAAyD,CAAC;QACrE,SAAI,GAA0B,EAAE,CAAC;IAMnC,CAAC;IALC,YAAY;QACV,OAAO,IAAI,CAAC,IAAI;aACb,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,GAAG,oCAAkB,GAAG,CAAC,CAAC,QAAQ,OAAO,IAAI,CAAC,kBAAkB,CAAC,CAAC,CAAC,eAAe,CAAC,EAAE,CAAC;aACjG,IAAI,CAAC,IAAI,CAAC,CAAC;IAChB,CAAC;CACF;AATD,0EASC"}
|
package/dist/multiple-envs.js
CHANGED
|
@@ -1,32 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.MultipleEnvs = void 0;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
constructor(...args) {
|
|
19
|
-
super(...args);
|
|
20
|
-
_defineProperty(this, "description", 'multiple envs');
|
|
21
|
-
_defineProperty(this, "solution", 'set the desired env by running "bit env set <component> <env>", if it doesn\'t work, run "bit aspect unset <component> <unwanted-env-id>". to keep troubleshooting run "bit aspect list <component-id>"');
|
|
22
|
-
_defineProperty(this, "data", void 0);
|
|
23
|
-
// env ids
|
|
24
|
-
_defineProperty(this, "isTagBlocker", true);
|
|
25
|
-
}
|
|
26
|
-
dataToString() {
|
|
27
|
-
return _componentIssue().ISSUE_FORMAT_SPACE + this.data.join(', ');
|
|
28
|
-
}
|
|
4
|
+
const component_issue_1 = require("./component-issue");
|
|
5
|
+
class MultipleEnvs extends component_issue_1.ComponentIssue {
|
|
6
|
+
constructor() {
|
|
7
|
+
super(...arguments);
|
|
8
|
+
this.description = 'multiple envs';
|
|
9
|
+
this.solution = 'set the desired env by running "bit env set <component> <env>", if it doesn\'t work, run "bit aspect unset <component> <unwanted-env-id>". to keep troubleshooting run "bit aspect list <component-id>"';
|
|
10
|
+
this.isTagBlocker = true;
|
|
11
|
+
}
|
|
12
|
+
dataToString() {
|
|
13
|
+
return component_issue_1.ISSUE_FORMAT_SPACE + this.data.join(', ');
|
|
14
|
+
}
|
|
29
15
|
}
|
|
30
16
|
exports.MultipleEnvs = MultipleEnvs;
|
|
31
|
-
|
|
32
17
|
//# sourceMappingURL=multiple-envs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"multiple-envs.js","sourceRoot":"","sources":["../multiple-envs.ts"],"names":[],"mappings":";;;AAAA,uDAAuE;AAEvE,MAAa,YAAa,SAAQ,gCAAc;IAAhD;;QACE,gBAAW,GAAG,eAAe,CAAC;QAC9B,aAAQ,GACN,yMAAyM,CAAC;QAE5M,iBAAY,GAAG,IAAI,CAAC;IAItB,CAAC;IAHC,YAAY;QACV,OAAO,oCAAkB,GAAG,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACnD,CAAC;CACF;AATD,oCASC"}
|
package/dist/non-loaded-env.js
CHANGED
|
@@ -1,31 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.NonLoadedEnv = void 0;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
constructor(...args) {
|
|
19
|
-
super(...args);
|
|
20
|
-
_defineProperty(this, "description", 'failed loading env');
|
|
21
|
-
_defineProperty(this, "solution", `run "bit install"`);
|
|
22
|
-
_defineProperty(this, "data", void 0);
|
|
23
|
-
_defineProperty(this, "isTagBlocker", true);
|
|
24
|
-
}
|
|
25
|
-
dataToString() {
|
|
26
|
-
return _componentIssue().ISSUE_FORMAT_SPACE + this.data;
|
|
27
|
-
}
|
|
4
|
+
const component_issue_1 = require("./component-issue");
|
|
5
|
+
class NonLoadedEnv extends component_issue_1.ComponentIssue {
|
|
6
|
+
constructor() {
|
|
7
|
+
super(...arguments);
|
|
8
|
+
this.description = 'failed loading env';
|
|
9
|
+
this.solution = `run "bit install"`;
|
|
10
|
+
this.isTagBlocker = true;
|
|
11
|
+
}
|
|
12
|
+
dataToString() {
|
|
13
|
+
return component_issue_1.ISSUE_FORMAT_SPACE + this.data;
|
|
14
|
+
}
|
|
28
15
|
}
|
|
29
16
|
exports.NonLoadedEnv = NonLoadedEnv;
|
|
30
|
-
|
|
31
17
|
//# sourceMappingURL=non-loaded-env.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"non-loaded-env.js","sourceRoot":"","sources":["../non-loaded-env.ts"],"names":[],"mappings":";;;AAAA,uDAAuE;AAEvE,MAAa,YAAa,SAAQ,gCAAc;IAAhD;;QACE,gBAAW,GAAG,oBAAoB,CAAC;QACnC,aAAQ,GAAG,mBAAmB,CAAC;QAE/B,iBAAY,GAAG,IAAI,CAAC;IAItB,CAAC;IAHC,YAAY;QACV,OAAO,oCAAkB,GAAG,IAAI,CAAC,IAAI,CAAC;IACxC,CAAC;CACF;AARD,oCAQC"}
|
package/dist/parse-errors.js
CHANGED
|
@@ -1,27 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.ParseErrors = void 0;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : String(i); }
|
|
16
|
-
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
17
|
-
class ParseErrors extends _componentIssue().ComponentIssue {
|
|
18
|
-
constructor(...args) {
|
|
19
|
-
super(...args);
|
|
20
|
-
_defineProperty(this, "description", 'error found while parsing the file');
|
|
21
|
-
_defineProperty(this, "solution", 'edit the file and fix the parsing error');
|
|
22
|
-
_defineProperty(this, "data", {});
|
|
23
|
-
}
|
|
4
|
+
const component_issue_1 = require("./component-issue");
|
|
5
|
+
class ParseErrors extends component_issue_1.ComponentIssue {
|
|
6
|
+
constructor() {
|
|
7
|
+
super(...arguments);
|
|
8
|
+
this.description = 'error found while parsing the file';
|
|
9
|
+
this.solution = 'edit the file and fix the parsing error';
|
|
10
|
+
this.data = {};
|
|
11
|
+
}
|
|
24
12
|
}
|
|
25
13
|
exports.ParseErrors = ParseErrors;
|
|
26
|
-
|
|
27
14
|
//# sourceMappingURL=parse-errors.js.map
|
package/dist/parse-errors.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"parse-errors.js","sourceRoot":"","sources":["../parse-errors.ts"],"names":[],"mappings":";;;AAAA,uDAAmD;AAEnD,MAAa,WAAY,SAAQ,gCAAc;IAA/C;;QACE,gBAAW,GAAG,oCAAoC,CAAC;QACnD,aAAQ,GAAG,yCAAyC,CAAC;QACrD,SAAI,GAAmC,EAAE,CAAC;IAC5C,CAAC;CAAA;AAJD,kCAIC"}
|
|
@@ -1,62 +1,43 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.RelativeComponentsAuthored = void 0;
|
|
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
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
return acc;
|
|
41
|
-
}, {});
|
|
42
|
-
return JSON.stringify(obj);
|
|
43
|
-
}
|
|
44
|
-
deserialize(dataStr) {
|
|
45
|
-
const data = JSON.parse(dataStr);
|
|
46
|
-
Object.keys(data).forEach(fileName => {
|
|
47
|
-
data[fileName] = data[fileName].map(record => ({
|
|
48
|
-
importSource: record.importSource,
|
|
49
|
-
componentId: _componentId().ComponentID.deserialize(record.componentId),
|
|
50
|
-
relativePath: record.relativePath
|
|
51
|
-
}));
|
|
52
|
-
});
|
|
53
|
-
return data;
|
|
54
|
-
}
|
|
4
|
+
const component_id_1 = require("@teambit/component-id");
|
|
5
|
+
const component_issue_1 = require("./component-issue");
|
|
6
|
+
class RelativeComponentsAuthored extends component_issue_1.ComponentIssue {
|
|
7
|
+
constructor() {
|
|
8
|
+
super(...arguments);
|
|
9
|
+
this.description = 'components with relative import statements found';
|
|
10
|
+
this.solution = 'replace to module paths or use "bit link --rewire" to replace';
|
|
11
|
+
this.data = {};
|
|
12
|
+
this.isCacheBlocker = false;
|
|
13
|
+
this.formatDataFunction = relativeComponentsAuthoredIssuesToString;
|
|
14
|
+
}
|
|
15
|
+
serialize() {
|
|
16
|
+
const obj = Object.keys(this.data).reduce((acc, fileName) => {
|
|
17
|
+
acc[fileName] = this.data[fileName].map((record) => ({
|
|
18
|
+
importSource: record.importSource,
|
|
19
|
+
componentId: record.componentId.serialize(),
|
|
20
|
+
relativePath: record.relativePath,
|
|
21
|
+
}));
|
|
22
|
+
return acc;
|
|
23
|
+
}, {});
|
|
24
|
+
return JSON.stringify(obj);
|
|
25
|
+
}
|
|
26
|
+
deserialize(dataStr) {
|
|
27
|
+
const data = JSON.parse(dataStr);
|
|
28
|
+
Object.keys(data).forEach((fileName) => {
|
|
29
|
+
data[fileName] = data[fileName].map((record) => ({
|
|
30
|
+
importSource: record.importSource,
|
|
31
|
+
componentId: component_id_1.ComponentID.deserialize(record.componentId),
|
|
32
|
+
relativePath: record.relativePath,
|
|
33
|
+
}));
|
|
34
|
+
});
|
|
35
|
+
return data;
|
|
36
|
+
}
|
|
55
37
|
}
|
|
56
38
|
exports.RelativeComponentsAuthored = RelativeComponentsAuthored;
|
|
57
39
|
function relativeComponentsAuthoredIssuesToString(relativeEntries) {
|
|
58
|
-
|
|
59
|
-
|
|
40
|
+
const stringifyEntry = (entry) => `"${entry.importSource}" (${entry.componentId.toString()})`;
|
|
41
|
+
return relativeEntries.map(stringifyEntry).join(', ');
|
|
60
42
|
}
|
|
61
|
-
|
|
62
43
|
//# sourceMappingURL=relative-components-authored.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"relative-components-authored.js","sourceRoot":"","sources":["../relative-components-authored.ts"],"names":[],"mappings":";;;AAAA,wDAAoD;AACpD,uDAAmD;AAWnD,MAAa,0BAA2B,SAAQ,gCAAc;IAA9D;;QACE,gBAAW,GAAG,kDAAkD,CAAC;QACjE,aAAQ,GAAG,+DAA+D,CAAC;QAC3E,SAAI,GAA8D,EAAE,CAAC;QACrE,mBAAc,GAAG,KAAK,CAAC;QACvB,uBAAkB,GAAG,wCAAwC,CAAC;IAyBhE,CAAC;IAvBC,SAAS;QACP,MAAM,GAAG,GAAG,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,MAAM,CAAC,CAAC,GAAG,EAAE,QAAQ,EAAE,EAAE;YAC1D,GAAG,CAAC,QAAQ,CAAC,GAAG,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC;gBACnD,YAAY,EAAE,MAAM,CAAC,YAAY;gBACjC,WAAW,EAAE,MAAM,CAAC,WAAW,CAAC,SAAS,EAAE;gBAC3C,YAAY,EAAE,MAAM,CAAC,YAAY;aAClC,CAAC,CAAC,CAAC;YACJ,OAAO,GAAG,CAAC;QACb,CAAC,EAAE,EAAE,CAAC,CAAC;QACP,OAAO,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC;IAED,WAAW,CAAC,OAAe;QACzB,MAAM,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QACjC,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC,QAAQ,EAAE,EAAE;YACrC,IAAI,CAAC,QAAQ,CAAC,GAAG,IAAI,CAAC,QAAQ,CAAC,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC;gBAC/C,YAAY,EAAE,MAAM,CAAC,YAAY;gBACjC,WAAW,EAAE,0BAAW,CAAC,WAAW,CAAC,MAAM,CAAC,WAAW,CAAC;gBACxD,YAAY,EAAE,MAAM,CAAC,YAAY;aAClC,CAAC,CAAC,CAAC;QACN,CAAC,CAAC,CAAC;QACH,OAAO,IAAI,CAAC;IACd,CAAC;CACF;AA9BD,gEA8BC;AAED,SAAS,wCAAwC,CAAC,eAAkD;IAClG,MAAM,cAAc,GAAG,CAAC,KAAsC,EAAE,EAAE,CAChE,IAAI,KAAK,CAAC,YAAY,MAAM,KAAK,CAAC,WAAW,CAAC,QAAQ,EAAE,GAAG,CAAC;IAC9D,OAAO,eAAe,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACxD,CAAC"}
|
|
@@ -1,31 +1,18 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.RelativeComponents = void 0;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
super(...args);
|
|
20
|
-
_defineProperty(this, "description", 'components with relative import statements found');
|
|
21
|
-
_defineProperty(this, "solution", 'use module paths for imported components');
|
|
22
|
-
_defineProperty(this, "data", {});
|
|
23
|
-
_defineProperty(this, "isCacheBlocker", false);
|
|
24
|
-
}
|
|
25
|
-
deserialize(data) {
|
|
26
|
-
return (0, _componentIssue().deserializeWithBitId)(data);
|
|
27
|
-
}
|
|
4
|
+
const component_issue_1 = require("./component-issue");
|
|
5
|
+
class RelativeComponents extends component_issue_1.ComponentIssue {
|
|
6
|
+
constructor() {
|
|
7
|
+
super(...arguments);
|
|
8
|
+
this.description = 'components with relative import statements found';
|
|
9
|
+
this.solution = 'use module paths for imported components';
|
|
10
|
+
this.data = {};
|
|
11
|
+
this.isCacheBlocker = false;
|
|
12
|
+
}
|
|
13
|
+
deserialize(data) {
|
|
14
|
+
return (0, component_issue_1.deserializeWithBitId)(data);
|
|
15
|
+
}
|
|
28
16
|
}
|
|
29
17
|
exports.RelativeComponents = RelativeComponents;
|
|
30
|
-
|
|
31
18
|
//# sourceMappingURL=relative-components.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"relative-components.js","sourceRoot":"","sources":["../relative-components.ts"],"names":[],"mappings":";;;AACA,uDAAyE;AAEzE,MAAa,kBAAmB,SAAQ,gCAAc;IAAtD;;QACE,gBAAW,GAAG,kDAAkD,CAAC;QACjE,aAAQ,GAAG,0CAA0C,CAAC;QACtD,SAAI,GAA0C,EAAE,CAAC;QACjD,mBAAc,GAAG,KAAK,CAAC;IAIzB,CAAC;IAHC,WAAW,CAAC,IAAY;QACtB,OAAO,IAAA,sCAAoB,EAAC,IAAI,CAAC,CAAC;IACpC,CAAC;CACF;AARD,gDAQC"}
|