@servicetitan/startup 23.1.0 → 23.2.1
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/dist/utils/get-configuration.d.ts +10 -6
- package/dist/utils/get-configuration.d.ts.map +1 -1
- package/dist/utils/get-configuration.js +47 -38
- package/dist/utils/get-configuration.js.map +1 -1
- package/dist/webpack/configs/plugins/ignore-plugin/check-resource.d.ts +2 -0
- package/dist/webpack/configs/plugins/ignore-plugin/check-resource.d.ts.map +1 -0
- package/dist/webpack/configs/plugins/ignore-plugin/check-resource.js +17 -0
- package/dist/webpack/configs/plugins/ignore-plugin/check-resource.js.map +1 -0
- package/dist/webpack/configs/plugins/ignore-plugin/ignore-plugin.d.ts +4 -0
- package/dist/webpack/configs/plugins/ignore-plugin/ignore-plugin.d.ts.map +1 -0
- package/dist/webpack/configs/plugins/ignore-plugin/ignore-plugin.js +15 -0
- package/dist/webpack/configs/plugins/ignore-plugin/ignore-plugin.js.map +1 -0
- package/dist/webpack/configs/plugins/ignore-plugin/index.d.ts +2 -0
- package/dist/webpack/configs/plugins/ignore-plugin/index.d.ts.map +1 -0
- package/dist/webpack/configs/plugins/ignore-plugin/index.js +18 -0
- package/dist/webpack/configs/plugins/ignore-plugin/index.js.map +1 -0
- package/dist/webpack/configs/plugins/ignore-plugin/is-optional-peer-dependency.d.ts +7 -0
- package/dist/webpack/configs/plugins/ignore-plugin/is-optional-peer-dependency.d.ts.map +1 -0
- package/dist/webpack/configs/plugins/ignore-plugin/is-optional-peer-dependency.js +8 -0
- package/dist/webpack/configs/plugins/ignore-plugin/is-optional-peer-dependency.js.map +1 -0
- package/dist/webpack/configs/plugins/index.d.ts +1 -0
- package/dist/webpack/configs/plugins/index.d.ts.map +1 -1
- package/dist/webpack/configs/plugins/index.js +1 -0
- package/dist/webpack/configs/plugins/index.js.map +1 -1
- package/dist/webpack/configs/plugins/virtual-modules-plugin.js +4 -3
- package/dist/webpack/configs/plugins/virtual-modules-plugin.js.map +1 -1
- package/dist/webpack/configs/plugins-config.d.ts.map +1 -1
- package/dist/webpack/configs/plugins-config.js +1 -0
- package/dist/webpack/configs/plugins-config.js.map +1 -1
- package/dist/webpack/configs/types.d.ts +1 -0
- package/dist/webpack/configs/types.d.ts.map +1 -1
- package/dist/webpack/create-webpack-config.d.ts.map +1 -1
- package/dist/webpack/create-webpack-config.js +1 -1
- package/dist/webpack/create-webpack-config.js.map +1 -1
- package/package.json +10 -9
- package/src/utils/__tests__/get-configuration.test.ts +17 -5
- package/src/utils/get-configuration.ts +54 -43
- package/src/webpack/__tests__/create-webpack-config-web-component.test.ts +34 -11
- package/src/webpack/__tests__/create-webpack-config.test.ts +21 -9
- package/src/webpack/configs/plugins/ignore-plugin/__tests__/check-resource.test.ts +37 -0
- package/src/webpack/configs/plugins/ignore-plugin/__tests__/is-optional-peer-dependency.test.ts +30 -0
- package/src/webpack/configs/plugins/ignore-plugin/check-resource.ts +12 -0
- package/src/webpack/configs/plugins/ignore-plugin/ignore-plugin.ts +13 -0
- package/src/webpack/configs/plugins/ignore-plugin/index.ts +1 -0
- package/src/webpack/configs/plugins/ignore-plugin/is-optional-peer-dependency.ts +10 -0
- package/src/webpack/configs/plugins/index.ts +1 -0
- package/src/webpack/configs/plugins/virtual-modules-plugin.ts +4 -3
- package/src/webpack/configs/plugins-config.ts +2 -0
- package/src/webpack/configs/types.ts +1 -0
- package/src/webpack/create-webpack-config.ts +2 -0
- package/template/packages/application/package.json +6 -6
- package/template-react18/packages/application/package.json +5 -5
|
@@ -37,6 +37,9 @@ export declare enum CommandName {
|
|
|
37
37
|
'styles-check' = "styles-check",
|
|
38
38
|
'test' = "test"
|
|
39
39
|
}
|
|
40
|
+
interface WebComponentOptions {
|
|
41
|
+
legacyRoot: boolean;
|
|
42
|
+
}
|
|
40
43
|
declare type Configuration = {
|
|
41
44
|
'legacy'?: boolean;
|
|
42
45
|
'lint'?: {
|
|
@@ -44,22 +47,23 @@ declare type Configuration = {
|
|
|
44
47
|
stylelint: StylelintConfiguration;
|
|
45
48
|
};
|
|
46
49
|
'test'?: JestConfiguration;
|
|
47
|
-
'web-component'?: boolean;
|
|
50
|
+
'web-component'?: boolean | WebComponentOptions;
|
|
48
51
|
'webpack'?: false | WebpackConfiguration;
|
|
49
52
|
} & {
|
|
50
53
|
[key in CommandName]: NodeConfiguration;
|
|
51
54
|
} & NodeConfiguration;
|
|
52
55
|
export declare function getConfiguration(location?: string): Configuration;
|
|
53
56
|
export declare function getConfigurationSafe(location?: string): Configuration;
|
|
57
|
+
export declare function getDevServerConfiguration(): Pick<WebpackDevServerConfiguration, "headers" | "port" | "proxy" | "contentBase"> | undefined;
|
|
58
|
+
export declare function getESLintConfiguration(): ESLintConfiguration;
|
|
59
|
+
export declare function getJestConfiguration(): JestConfiguration & NodeConfiguration;
|
|
60
|
+
export declare function getStylelintConfiguration(): StylelintConfiguration;
|
|
54
61
|
export declare function isBundle(location?: string): boolean;
|
|
55
62
|
export declare function isCustomStyleRules(): boolean;
|
|
56
63
|
export declare function isExposeSharedDependencies(): boolean;
|
|
57
|
-
export declare function getDevServerConfiguration(): Pick<WebpackDevServerConfiguration, "headers" | "port" | "proxy" | "contentBase"> | undefined;
|
|
58
|
-
export declare function isWebComponent(): boolean;
|
|
59
64
|
export declare function isLegacy(location?: string): boolean;
|
|
60
|
-
export declare function
|
|
61
|
-
export declare function getStylelintConfiguration(): StylelintConfiguration;
|
|
62
|
-
export declare function getJestConfiguration(): JestConfiguration & NodeConfiguration;
|
|
65
|
+
export declare function isLegacyRoot(): boolean;
|
|
63
66
|
export declare function isStyleCheckDisabled(): boolean;
|
|
67
|
+
export declare function isWebComponent(): boolean;
|
|
64
68
|
export {};
|
|
65
69
|
//# sourceMappingURL=get-configuration.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-configuration.d.ts","sourceRoot":"","sources":["../../src/utils/get-configuration.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,aAAa,IAA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,wBAAgB,sBAAsB,wBAErC;AAED,wBAAgB,oBAAoB,0CAEnC;AAED,wBAAgB,yBAAyB,2BAExC;AAED,wBAAgB,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,WAEzC;AAED,wBAAgB,kBAAkB,YAQjC;AAED,wBAAgB,0BAA0B,YAQzC;AAED,wBAAgB,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,WAEzC;AAED,wBAAgB,YAAY,YAG3B;AAED,wBAAgB,oBAAoB,YAQnC;AAED,wBAAgB,cAAc,YAG7B"}
|
|
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.isStyleCheckDisabled = exports.
|
|
6
|
+
exports.isWebComponent = exports.isStyleCheckDisabled = exports.isLegacyRoot = exports.isLegacy = exports.isExposeSharedDependencies = exports.isCustomStyleRules = exports.isBundle = exports.getStylelintConfiguration = exports.getJestConfiguration = exports.getESLintConfiguration = exports.getDevServerConfiguration = exports.getConfigurationSafe = exports.getConfiguration = exports.CommandName = void 0;
|
|
7
7
|
const fs_1 = __importDefault(require("fs"));
|
|
8
8
|
const path_1 = __importDefault(require("path"));
|
|
9
9
|
const read_json_1 = require("./read-json");
|
|
@@ -36,31 +36,6 @@ function getConfigurationSafe(location = './') {
|
|
|
36
36
|
return (_b = (_a = (0, read_json_1.readJsonSafe)(path_1.default.join(location, 'package.json'))) === null || _a === void 0 ? void 0 : _a.cli) !== null && _b !== void 0 ? _b : {};
|
|
37
37
|
}
|
|
38
38
|
exports.getConfigurationSafe = getConfigurationSafe;
|
|
39
|
-
function isBundle(location) {
|
|
40
|
-
return getConfiguration(location).webpack !== false;
|
|
41
|
-
}
|
|
42
|
-
exports.isBundle = isBundle;
|
|
43
|
-
function isCustomStyleRules() {
|
|
44
|
-
const configuration = getConfiguration();
|
|
45
|
-
if (typeof configuration.webpack !== 'object') {
|
|
46
|
-
return false;
|
|
47
|
-
}
|
|
48
|
-
return configuration.webpack['custom-style-rules'] === true;
|
|
49
|
-
}
|
|
50
|
-
exports.isCustomStyleRules = isCustomStyleRules;
|
|
51
|
-
function isExposeSharedDependencies() {
|
|
52
|
-
const configuration = getConfiguration();
|
|
53
|
-
if (typeof configuration.webpack !== 'object') {
|
|
54
|
-
return false;
|
|
55
|
-
}
|
|
56
|
-
return configuration.webpack['expose-shared-dependencies'] === true;
|
|
57
|
-
}
|
|
58
|
-
exports.isExposeSharedDependencies = isExposeSharedDependencies;
|
|
59
|
-
function pick(target, keys) {
|
|
60
|
-
return Object.fromEntries(keys
|
|
61
|
-
.filter(key => Object.prototype.hasOwnProperty.call(target, key))
|
|
62
|
-
.map(key => [key, target[key]]));
|
|
63
|
-
}
|
|
64
39
|
function getDevServerConfiguration() {
|
|
65
40
|
const configuration = getConfiguration();
|
|
66
41
|
if (typeof configuration.webpack !== 'object') {
|
|
@@ -78,29 +53,50 @@ function getDevServerConfiguration() {
|
|
|
78
53
|
return result;
|
|
79
54
|
}
|
|
80
55
|
exports.getDevServerConfiguration = getDevServerConfiguration;
|
|
81
|
-
function isWebComponent() {
|
|
82
|
-
return getConfiguration()['web-component'] === true;
|
|
83
|
-
}
|
|
84
|
-
exports.isWebComponent = isWebComponent;
|
|
85
|
-
function isLegacy(location) {
|
|
86
|
-
return getConfiguration(location).legacy === true;
|
|
87
|
-
}
|
|
88
|
-
exports.isLegacy = isLegacy;
|
|
89
56
|
function getESLintConfiguration() {
|
|
90
57
|
var _a, _b;
|
|
91
58
|
return (_b = (_a = getConfiguration().lint) === null || _a === void 0 ? void 0 : _a.eslint) !== null && _b !== void 0 ? _b : {};
|
|
92
59
|
}
|
|
93
60
|
exports.getESLintConfiguration = getESLintConfiguration;
|
|
61
|
+
function getJestConfiguration() {
|
|
62
|
+
var _a;
|
|
63
|
+
return (_a = getConfiguration().test) !== null && _a !== void 0 ? _a : {};
|
|
64
|
+
}
|
|
65
|
+
exports.getJestConfiguration = getJestConfiguration;
|
|
94
66
|
function getStylelintConfiguration() {
|
|
95
67
|
var _a, _b;
|
|
96
68
|
return (_b = (_a = getConfiguration().lint) === null || _a === void 0 ? void 0 : _a.stylelint) !== null && _b !== void 0 ? _b : {};
|
|
97
69
|
}
|
|
98
70
|
exports.getStylelintConfiguration = getStylelintConfiguration;
|
|
99
|
-
function
|
|
100
|
-
|
|
101
|
-
return (_a = getConfiguration().test) !== null && _a !== void 0 ? _a : {};
|
|
71
|
+
function isBundle(location) {
|
|
72
|
+
return getConfiguration(location).webpack !== false;
|
|
102
73
|
}
|
|
103
|
-
exports.
|
|
74
|
+
exports.isBundle = isBundle;
|
|
75
|
+
function isCustomStyleRules() {
|
|
76
|
+
const configuration = getConfiguration();
|
|
77
|
+
if (typeof configuration.webpack !== 'object') {
|
|
78
|
+
return false;
|
|
79
|
+
}
|
|
80
|
+
return configuration.webpack['custom-style-rules'] === true;
|
|
81
|
+
}
|
|
82
|
+
exports.isCustomStyleRules = isCustomStyleRules;
|
|
83
|
+
function isExposeSharedDependencies() {
|
|
84
|
+
const configuration = getConfiguration();
|
|
85
|
+
if (typeof configuration.webpack !== 'object') {
|
|
86
|
+
return false;
|
|
87
|
+
}
|
|
88
|
+
return configuration.webpack['expose-shared-dependencies'] === true;
|
|
89
|
+
}
|
|
90
|
+
exports.isExposeSharedDependencies = isExposeSharedDependencies;
|
|
91
|
+
function isLegacy(location) {
|
|
92
|
+
return getConfiguration(location).legacy === true;
|
|
93
|
+
}
|
|
94
|
+
exports.isLegacy = isLegacy;
|
|
95
|
+
function isLegacyRoot() {
|
|
96
|
+
const config = getConfiguration()['web-component'];
|
|
97
|
+
return typeof config === 'object' && config.legacyRoot === true;
|
|
98
|
+
}
|
|
99
|
+
exports.isLegacyRoot = isLegacyRoot;
|
|
104
100
|
function isStyleCheckDisabled() {
|
|
105
101
|
var _a;
|
|
106
102
|
const configuration = getConfiguration();
|
|
@@ -110,4 +106,17 @@ function isStyleCheckDisabled() {
|
|
|
110
106
|
return ((_a = configuration.webpack) === null || _a === void 0 ? void 0 : _a['disable-style-check']) === true;
|
|
111
107
|
}
|
|
112
108
|
exports.isStyleCheckDisabled = isStyleCheckDisabled;
|
|
109
|
+
function isWebComponent() {
|
|
110
|
+
const config = getConfiguration()['web-component'];
|
|
111
|
+
return config === true || typeof config === 'object';
|
|
112
|
+
}
|
|
113
|
+
exports.isWebComponent = isWebComponent;
|
|
114
|
+
function pick(target, keys) {
|
|
115
|
+
return keys.reduce((result, key) => {
|
|
116
|
+
if (Object.hasOwn(target, key)) {
|
|
117
|
+
result[key] = target[key];
|
|
118
|
+
}
|
|
119
|
+
return result;
|
|
120
|
+
}, {});
|
|
121
|
+
}
|
|
113
122
|
//# sourceMappingURL=get-configuration.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-configuration.js","sourceRoot":"","sources":["../../src/utils/get-configuration.ts"],"names":[],"mappings":";;;;;;AAAA,4CAAoB;AACpB,gDAAwB;AAMxB,2CAAqD;AAErD,MAAM,8BAA8B,GAAG,CAAC,SAAS,EAAE,MAAM,EAAE,OAAO,EAAE,aAAa,CAAU,CAAC;AA+B5F,yDAAyD;AACzD,IAAY,WAeX;AAfD,WAAY,WAAW;IACnB,8BAAiB,CAAA;IACjB,gDAAmC,CAAA;IACnC,gCAAmB,CAAA;IACnB,4BAAe,CAAA;IACf,kCAAqB,CAAA;IACrB,oDAAuC,CAAA;IACvC,4BAAe,CAAA;IACf,sDAAyC,CAAA;IACzC,0DAA6C,CAAA;IAC7C,0CAA6B,CAAA;IAC7B,kDAAqC,CAAA;IACrC,8BAAiB,CAAA;IACjB,4CAA+B,CAAA;IAC/B,4BAAe,CAAA;AACnB,CAAC,EAfW,WAAW,GAAX,mBAAW,KAAX,mBAAW,QAetB;
|
|
1
|
+
{"version":3,"file":"get-configuration.js","sourceRoot":"","sources":["../../src/utils/get-configuration.ts"],"names":[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":[],"mappings":"AAEA,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,WAS9D"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.checkResource = void 0;
|
|
4
|
+
const is_optional_peer_dependency_1 = require("./is-optional-peer-dependency");
|
|
5
|
+
function checkResource(resource, context) {
|
|
6
|
+
if ((0, is_optional_peer_dependency_1.isOptionalPeerDependency)({ resource, context })) {
|
|
7
|
+
try {
|
|
8
|
+
require.resolve(resource);
|
|
9
|
+
}
|
|
10
|
+
catch (e) {
|
|
11
|
+
return true;
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
return false;
|
|
15
|
+
}
|
|
16
|
+
exports.checkResource = checkResource;
|
|
17
|
+
//# sourceMappingURL=check-resource.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"check-resource.js","sourceRoot":"","sources":["../../../../../src/webpack/configs/plugins/ignore-plugin/check-resource.ts"],"names":[],"mappings":";;;AAAA,+EAAyE;AAEzE,SAAgB,aAAa,CAAC,QAAgB,EAAE,OAAe;IAC3D,IAAI,IAAA,sDAAwB,EAAC,EAAE,QAAQ,EAAE,OAAO,EAAE,CAAC,EAAE;QACjD,IAAI;YACA,OAAO,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC;SAC7B;QAAC,OAAO,CAAC,EAAE;YACR,OAAO,IAAI,CAAC;SACf;KACJ;IACD,OAAO,KAAK,CAAC;AACjB,CAAC;AATD,sCASC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ignore-plugin.d.ts","sourceRoot":"","sources":["../../../../../src/webpack/configs/plugins/ignore-plugin/ignore-plugin.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAEvC,OAAO,EAAE,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAGjD,wBAAgB,YAAY,CAAC,QAAQ,EAAE,OAAO,EAAE,CAAC,EAAE,SAAS,gBAO3D"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ignorePlugin = void 0;
|
|
4
|
+
const webpack_1 = require("webpack");
|
|
5
|
+
const check_resource_1 = require("./check-resource");
|
|
6
|
+
function ignorePlugin(_context, _) {
|
|
7
|
+
/**
|
|
8
|
+
* Ignore optional peer dependencies
|
|
9
|
+
* @see {@link: file://./../../../../../../web-components/src/render.ts}
|
|
10
|
+
* @see {@link: file://./../../../../../../ko-bridge/src/ko-binding-handlers.tsx}
|
|
11
|
+
*/
|
|
12
|
+
return new webpack_1.IgnorePlugin({ checkResource: check_resource_1.checkResource });
|
|
13
|
+
}
|
|
14
|
+
exports.ignorePlugin = ignorePlugin;
|
|
15
|
+
//# sourceMappingURL=ignore-plugin.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ignore-plugin.js","sourceRoot":"","sources":["../../../../../src/webpack/configs/plugins/ignore-plugin/ignore-plugin.ts"],"names":[],"mappings":";;;AAAA,qCAAuC;AAGvC,qDAAiD;AAEjD,SAAgB,YAAY,CAAC,QAAiB,EAAE,CAAY;IACxD;;;;OAIG;IACH,OAAO,IAAI,sBAAY,CAAC,EAAE,aAAa,EAAb,8BAAa,EAAE,CAAC,CAAC;AAC/C,CAAC;AAPD,oCAOC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/webpack/configs/plugins/ignore-plugin/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./ignore-plugin"), exports);
|
|
18
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/webpack/configs/plugins/ignore-plugin/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,kDAAgC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"is-optional-peer-dependency.d.ts","sourceRoot":"","sources":["../../../../../src/webpack/configs/plugins/ignore-plugin/is-optional-peer-dependency.ts"],"names":[],"mappings":"AAAA,UAAU,UAAU;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;CACpB;AAED,wBAAgB,wBAAwB,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,UAAU,WAIzE"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.isOptionalPeerDependency = void 0;
|
|
4
|
+
function isOptionalPeerDependency({ context, resource }) {
|
|
5
|
+
return (resource === 'react-dom/client' && /@servicetitan\/(ko-bridge|web-components)/.test(context));
|
|
6
|
+
}
|
|
7
|
+
exports.isOptionalPeerDependency = isOptionalPeerDependency;
|
|
8
|
+
//# sourceMappingURL=is-optional-peer-dependency.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"is-optional-peer-dependency.js","sourceRoot":"","sources":["../../../../../src/webpack/configs/plugins/ignore-plugin/is-optional-peer-dependency.ts"],"names":[],"mappings":";;;AAKA,SAAgB,wBAAwB,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAc;IACtE,OAAO,CACH,QAAQ,KAAK,kBAAkB,IAAI,2CAA2C,CAAC,IAAI,CAAC,OAAO,CAAC,CAC/F,CAAC;AACN,CAAC;AAJD,4DAIC"}
|
|
@@ -4,6 +4,7 @@ export * from './define-exposed-dependencies-plugin';
|
|
|
4
4
|
export * from './define-web-component-name-plugin';
|
|
5
5
|
export * from './filter-warnings-plugin';
|
|
6
6
|
export * from './html-plugin';
|
|
7
|
+
export * from './ignore-plugin';
|
|
7
8
|
export * from './mini-css-extract-plugin';
|
|
8
9
|
export * from './moment-locales-plugin';
|
|
9
10
|
export * from './provide-react-plugin';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/webpack/configs/plugins/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,cAAc,sCAAsC,CAAC;AACrD,cAAc,oCAAoC,CAAC;AACnD,cAAc,0BAA0B,CAAC;AACzC,cAAc,eAAe,CAAC;AAC9B,cAAc,2BAA2B,CAAC;AAC1C,cAAc,yBAAyB,CAAC;AACxC,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC;AACpC,cAAc,0BAA0B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/webpack/configs/plugins/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,cAAc,sCAAsC,CAAC;AACrD,cAAc,oCAAoC,CAAC;AACnD,cAAc,0BAA0B,CAAC;AACzC,cAAc,eAAe,CAAC;AAC9B,cAAc,iBAAiB,CAAC;AAChC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,yBAAyB,CAAC;AACxC,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC;AACpC,cAAc,0BAA0B,CAAC"}
|
|
@@ -20,6 +20,7 @@ __exportStar(require("./define-exposed-dependencies-plugin"), exports);
|
|
|
20
20
|
__exportStar(require("./define-web-component-name-plugin"), exports);
|
|
21
21
|
__exportStar(require("./filter-warnings-plugin"), exports);
|
|
22
22
|
__exportStar(require("./html-plugin"), exports);
|
|
23
|
+
__exportStar(require("./ignore-plugin"), exports);
|
|
23
24
|
__exportStar(require("./mini-css-extract-plugin"), exports);
|
|
24
25
|
__exportStar(require("./moment-locales-plugin"), exports);
|
|
25
26
|
__exportStar(require("./provide-react-plugin"), exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/webpack/configs/plugins/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2DAAyC;AACzC,2DAAyC;AACzC,uEAAqD;AACrD,qEAAmD;AACnD,2DAAyC;AACzC,gDAA8B;AAC9B,4DAA0C;AAC1C,0DAAwC;AACxC,yDAAuC;AACvC,sDAAoC;AACpC,2DAAyC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/webpack/configs/plugins/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2DAAyC;AACzC,2DAAyC;AACzC,uEAAqD;AACrD,qEAAmD;AACnD,2DAAyC;AACzC,gDAA8B;AAC9B,kDAAgC;AAChC,4DAA0C;AAC1C,0DAAwC;AACxC,yDAAuC;AACvC,sDAAoC;AACpC,2DAAyC"}
|
|
@@ -30,13 +30,14 @@ function designSystemCode() {
|
|
|
30
30
|
`@import '~@servicetitan/design-system/dist/system.min.css';`,
|
|
31
31
|
].join('\n');
|
|
32
32
|
}
|
|
33
|
-
function indexCode({ embed }) {
|
|
33
|
+
function indexCode({ embed, isLegacyRoot }) {
|
|
34
|
+
const options = `{ legacyRoot: ${isLegacyRoot} }`;
|
|
34
35
|
return [
|
|
35
36
|
`import { register } from '@servicetitan/web-components';`,
|
|
36
37
|
`import { App } from './app';`,
|
|
37
38
|
...(embed
|
|
38
|
-
? [`register(App, true);`]
|
|
39
|
-
: [`require('./design-system.css');`, `register(App, false);`]),
|
|
39
|
+
? [`register(App, true, ${options});`]
|
|
40
|
+
: [`require('./design-system.css');`, `register(App, false, ${options});`]),
|
|
40
41
|
].join('\n');
|
|
41
42
|
}
|
|
42
43
|
//# sourceMappingURL=virtual-modules-plugin.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"virtual-modules-plugin.js","sourceRoot":"","sources":["../../../../src/webpack/configs/plugins/virtual-modules-plugin.ts"],"names":[],"mappings":";;;;;;AAAA,4CAAoB;AACpB,gDAAwB;AACxB,sFAA2D;AAG3D,SAAgB,oBAAoB,CAAC,OAAgB,EAAE,CAAY;IAC/D,IAAI,CAAC,OAAO,CAAC,cAAc,EAAE;QACzB,OAAO;KACV;IAED,MAAM,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC;IAE3B,MAAM,SAAS,GAAG,cAAI,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,GAAG,MAAM,WAAW,CAAC,CAAC;IACjE,MAAM,OAAO,GAA0D;QACnE,CAAC,SAAS,CAAC,EAAE,SAAS,CAAC,OAAO,CAAC;KAClC,CAAC;IAEF,MAAM,gBAAgB,GAAG,cAAI,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,GAAG,MAAM,oBAAoB,CAAC,CAAC;IACjF,IAAI,CAAC,YAAE,CAAC,UAAU,CAAC,gBAAgB,CAAC,EAAE;QAClC,OAAO,CAAC,gBAAgB,CAAC,GAAG,gBAAgB,EAAE,CAAC;KAClD;IAED,OAAO,IAAI,iCAAoB,CAAC,OAAO,CAAC,CAAC;AAC7C,CAAC;AAlBD,oDAkBC;AAED,SAAS,gBAAgB;IACrB,OAAO;QACH,kDAAkD;QAClD,gEAAgE;QAChE,6DAA6D;KAChE,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACjB,CAAC;AAED,SAAS,SAAS,CAAC,EAAE,KAAK,EAAW;
|
|
1
|
+
{"version":3,"file":"virtual-modules-plugin.js","sourceRoot":"","sources":["../../../../src/webpack/configs/plugins/virtual-modules-plugin.ts"],"names":[],"mappings":";;;;;;AAAA,4CAAoB;AACpB,gDAAwB;AACxB,sFAA2D;AAG3D,SAAgB,oBAAoB,CAAC,OAAgB,EAAE,CAAY;IAC/D,IAAI,CAAC,OAAO,CAAC,cAAc,EAAE;QACzB,OAAO;KACV;IAED,MAAM,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC;IAE3B,MAAM,SAAS,GAAG,cAAI,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,GAAG,MAAM,WAAW,CAAC,CAAC;IACjE,MAAM,OAAO,GAA0D;QACnE,CAAC,SAAS,CAAC,EAAE,SAAS,CAAC,OAAO,CAAC;KAClC,CAAC;IAEF,MAAM,gBAAgB,GAAG,cAAI,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,GAAG,MAAM,oBAAoB,CAAC,CAAC;IACjF,IAAI,CAAC,YAAE,CAAC,UAAU,CAAC,gBAAgB,CAAC,EAAE;QAClC,OAAO,CAAC,gBAAgB,CAAC,GAAG,gBAAgB,EAAE,CAAC;KAClD;IAED,OAAO,IAAI,iCAAoB,CAAC,OAAO,CAAC,CAAC;AAC7C,CAAC;AAlBD,oDAkBC;AAED,SAAS,gBAAgB;IACrB,OAAO;QACH,kDAAkD;QAClD,gEAAgE;QAChE,6DAA6D;KAChE,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACjB,CAAC;AAED,SAAS,SAAS,CAAC,EAAE,KAAK,EAAE,YAAY,EAAW;IAC/C,MAAM,OAAO,GAAG,iBAAiB,YAAY,IAAI,CAAC;IAClD,OAAO;QACH,0DAA0D;QAC1D,8BAA8B;QAC9B,GAAG,CAAC,KAAK;YACL,CAAC,CAAC,CAAC,uBAAuB,OAAO,IAAI,CAAC;YACtC,CAAC,CAAC,CAAC,iCAAiC,EAAE,wBAAwB,OAAO,IAAI,CAAC,CAAC;KAClF,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACjB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugins-config.d.ts","sourceRoot":"","sources":["../../../src/webpack/configs/plugins-config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"plugins-config.d.ts","sourceRoot":"","sources":["../../../src/webpack/configs/plugins-config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAexC,OAAO,EAAE,OAAO,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAG7C,aAAK,MAAM,GAAG,IAAI,CAAC,aAAa,EAAE,SAAS,CAAC,CAAC;AAE7C,wBAAgB,aAAa,CAAC,OAAO,EAAE,OAAO,EAAE,SAAS,EAAE,SAAS,GAAG,MAAM,CAmB5E"}
|
|
@@ -10,6 +10,7 @@ function pluginsConfig(context, overrides) {
|
|
|
10
10
|
plugins_1.defineWebComponentNamePlugin,
|
|
11
11
|
plugins_1.filterWarningsPlugin,
|
|
12
12
|
plugins_1.htmlPlugin,
|
|
13
|
+
plugins_1.ignorePlugin,
|
|
13
14
|
plugins_1.miniCssExtractPlugin,
|
|
14
15
|
plugins_1.momentLocalesPlugin,
|
|
15
16
|
plugins_1.tsCheckerPlugin,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugins-config.js","sourceRoot":"","sources":["../../../src/webpack/configs/plugins-config.ts"],"names":[],"mappings":";;;AACA,
|
|
1
|
+
{"version":3,"file":"plugins-config.js","sourceRoot":"","sources":["../../../src/webpack/configs/plugins-config.ts"],"names":[],"mappings":";;;AACA,uCAamB;AAMnB,SAAgB,aAAa,CAAC,OAAgB,EAAE,SAAoB;IAChE,MAAM,OAAO,GAAW;QACpB,8BAAoB;QACpB,8BAAoB;QACpB,yCAA+B;QAC/B,sCAA4B;QAC5B,8BAAoB;QACpB,oBAAU;QACV,sBAAY;QACZ,8BAAoB;QACpB,6BAAmB;QACnB,yBAAe;QACf,4BAAkB;QAClB,8BAAoB;KACvB;SACI,GAAG,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,OAAO,EAAE,SAAS,CAAC,CAAC;SACjC,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC;IAEhC,OAAO,EAAE,OAAO,EAAE,CAAC;AACvB,CAAC;AAnBD,sCAmBC"}
|
|
@@ -8,6 +8,7 @@ export interface Context extends Options {
|
|
|
8
8
|
experimentalBundlers: boolean;
|
|
9
9
|
isCustomStyleRules: boolean;
|
|
10
10
|
isExposeSharedDependencies: boolean;
|
|
11
|
+
isLegacyRoot: boolean;
|
|
11
12
|
isProduction: boolean;
|
|
12
13
|
isWebComponent: boolean;
|
|
13
14
|
packageData: ReturnType<typeof getPackageData>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/webpack/configs/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,sBAAsB,EAAE,MAAM,aAAa,CAAC;AACrE,OAAO,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AACnC,OAAO,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAErC,MAAM,WAAW,OAAQ,SAAQ,OAAO;IACpC,YAAY,EAAE,OAAO,CAAC;IACtB,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,OAAO,CAAC;IACjB,oBAAoB,EAAE,OAAO,CAAC;IAC9B,kBAAkB,EAAE,OAAO,CAAC;IAC5B,0BAA0B,EAAE,OAAO,CAAC;IACpC,YAAY,EAAE,OAAO,CAAC;IACtB,cAAc,EAAE,OAAO,CAAC;IACxB,WAAW,EAAE,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;IAC/C,kBAAkB,EAAE,UAAU,CAAC,OAAO,sBAAsB,CAAC,CAAC;IAC9D,MAAM,EAAE,MAAM,CAAC;CAClB"}
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/webpack/configs/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,sBAAsB,EAAE,MAAM,aAAa,CAAC;AACrE,OAAO,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AACnC,OAAO,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAErC,MAAM,WAAW,OAAQ,SAAQ,OAAO;IACpC,YAAY,EAAE,OAAO,CAAC;IACtB,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,OAAO,CAAC;IACjB,oBAAoB,EAAE,OAAO,CAAC;IAC9B,kBAAkB,EAAE,OAAO,CAAC;IAC5B,0BAA0B,EAAE,OAAO,CAAC;IACpC,YAAY,EAAE,OAAO,CAAC;IACtB,YAAY,EAAE,OAAO,CAAC;IACtB,cAAc,EAAE,OAAO,CAAC;IACxB,WAAW,EAAE,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;IAC/C,kBAAkB,EAAE,UAAU,CAAC,OAAO,sBAAsB,CAAC,CAAC;IAC9D,MAAM,EAAE,MAAM,CAAC;CAClB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-webpack-config.d.ts","sourceRoot":"","sources":["../../src/webpack/create-webpack-config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"create-webpack-config.d.ts","sourceRoot":"","sources":["../../src/webpack/create-webpack-config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AA8BxC,OAAO,EAAE,OAAO,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAG7C,wBAAgB,mBAAmB,CAAC,SAAS,EAAE,SAAS,EAAE,OAAO,GAAE,OAAY,GAAG,aAAa,CAwD9F"}
|
|
@@ -16,7 +16,7 @@ function createWebpackConfig(overrides, options = {}) {
|
|
|
16
16
|
const { source, destination } = (0, utils_2.getFolders)();
|
|
17
17
|
const packageData = (0, utils_2.getPackageData)();
|
|
18
18
|
const sharedDependencies = (0, utils_2.loadSharedDependencies)(packageData.dependencies, packageData.sharedDependencies);
|
|
19
|
-
const context = Object.assign(Object.assign({ codeCoverage: (_a = options.codeCoverage) !== null && _a !== void 0 ? _a : !!yargs_1.argv['code-coverage'], destination, esbuild: (_b = options.esbuild) !== null && _b !== void 0 ? _b : !!yargs_1.argv.esbuild, experimentalBundlers: (_c = options.experimentalBundlers) !== null && _c !== void 0 ? _c : !!yargs_1.argv['experimental-bundlers'], isCustomStyleRules: (0, utils_2.isCustomStyleRules)(), isExposeSharedDependencies: (0, utils_2.isExposeSharedDependencies)(), isProduction: configuration.mode === 'production', isWebComponent: (0, utils_2.isWebComponent)(), name: '' }, options), { packageData,
|
|
19
|
+
const context = Object.assign(Object.assign({ codeCoverage: (_a = options.codeCoverage) !== null && _a !== void 0 ? _a : !!yargs_1.argv['code-coverage'], destination, esbuild: (_b = options.esbuild) !== null && _b !== void 0 ? _b : !!yargs_1.argv.esbuild, experimentalBundlers: (_c = options.experimentalBundlers) !== null && _c !== void 0 ? _c : !!yargs_1.argv['experimental-bundlers'], isCustomStyleRules: (0, utils_2.isCustomStyleRules)(), isExposeSharedDependencies: (0, utils_2.isExposeSharedDependencies)(), isLegacyRoot: (0, utils_2.isLegacyRoot)(), isProduction: configuration.mode === 'production', isWebComponent: (0, utils_2.isWebComponent)(), name: '' }, options), { packageData,
|
|
20
20
|
sharedDependencies,
|
|
21
21
|
source });
|
|
22
22
|
if (context.isWebComponent && isCalledFromCustomWebpackConfigFile()) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-webpack-config.js","sourceRoot":"","sources":["../../src/webpack/create-webpack-config.ts"],"names":[],"mappings":";;;;;;AACA,kEAAkC;AAClC,iCAAwC;AAExC,wCAAmF;AACnF,
|
|
1
|
+
{"version":3,"file":"create-webpack-config.js","sourceRoot":"","sources":["../../src/webpack/create-webpack-config.ts"],"names":[],"mappings":";;;;;;AACA,kEAAkC;AAClC,iCAAwC;AAExC,wCAAmF;AACnF,oCASkB;AAClB,uCAcmB;AAEnB,mCAAwC;AAExC,SAAgB,mBAAmB,CAAC,SAAoB,EAAE,UAAmB,EAAE;;IAC3E,MAAM,EAAE,aAAa,GAAG,EAAE,EAAE,GAAG,SAAS,CAAC;IAEzC,MAAM,EAAE,MAAM,EAAE,WAAW,EAAE,GAAG,IAAA,kBAAU,GAAE,CAAC;IAC7C,MAAM,WAAW,GAAG,IAAA,sBAAc,GAAE,CAAC;IACrC,MAAM,kBAAkB,GAAG,IAAA,8BAAsB,EAC7C,WAAW,CAAC,YAAY,EACxB,WAAW,CAAC,kBAAkB,CACjC,CAAC;IAEF,MAAM,OAAO,iCACT,YAAY,EAAE,MAAA,OAAO,CAAC,YAAY,mCAAI,CAAC,CAAE,YAAkB,CAAC,eAAe,CAAC,EAC5E,WAAW,EACX,OAAO,EAAE,MAAA,OAAO,CAAC,OAAO,mCAAI,CAAC,CAAE,YAAkB,CAAC,OAAO,EACzD,oBAAoB,EAChB,MAAA,OAAO,CAAC,oBAAoB,mCAAI,CAAC,CAAE,YAAkB,CAAC,uBAAuB,CAAC,EAClF,kBAAkB,EAAE,IAAA,0BAAkB,GAAE,EACxC,0BAA0B,EAAE,IAAA,kCA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AAK,CAAC,IAAI,mCAAI,EAAE,GAAG,CAAC;SAC1C;QACD,IAAI,KAAK,YAAY,MAAM,EAAE;YACzB,OAAO,MAAM,CAAC,KAAK,CAAC,CAAC;SACxB;QACD,IAAI,GAAG,KAAK,SAAS,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE;YAC3C,OAAO,KAAK,CAAC,GAAG,CAAC,MAAM,CAAC,EAAE;;gBACtB,MAAM,IAAI,GAAG,MAAA,MAAA,MAAM,CAAC,WAAW,0CAAE,IAAI,mCAAI,MAAM,CAAC,IAAI,CAAC;gBACrD,OAAO,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC;YAC9C,CAAC,CAAC,CAAC;SACN;QACD,OAAO,KAAK,CAAC;IACjB,CAAC;IACD,OAAO,IAAI,CAAC,SAAS,CAAC,aAAa,EAAE,QAAQ,EAAE,CAAC,CAAC,CAAC;AACtD,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@servicetitan/startup",
|
|
3
|
-
"version": "23.1
|
|
3
|
+
"version": "23.2.1",
|
|
4
4
|
"description": "",
|
|
5
5
|
"homepage": "https://docs.st.dev/docs/frontend/startup",
|
|
6
6
|
"repository": {
|
|
@@ -35,16 +35,17 @@
|
|
|
35
35
|
"@types/yargs": "~17.0.24"
|
|
36
36
|
},
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@babel/preset-env": "~7.
|
|
38
|
+
"@babel/preset-env": "~7.24.0",
|
|
39
39
|
"@jest/core": "~29.7.0",
|
|
40
40
|
"@jest/types": "~29.6.3",
|
|
41
41
|
"@lerna/exec": "~5.6.2",
|
|
42
|
-
"@servicetitan/eslint-config": "23.1
|
|
43
|
-
"@servicetitan/stylelint-config": "23.1
|
|
44
|
-
"@swc/core": "1.
|
|
45
|
-
"@types/
|
|
42
|
+
"@servicetitan/eslint-config": "23.2.1",
|
|
43
|
+
"@servicetitan/stylelint-config": "23.2.1",
|
|
44
|
+
"@swc/core": "1.4.6",
|
|
45
|
+
"@types/debug": "^4.1.12",
|
|
46
|
+
"@types/jest": "~29.5.12",
|
|
46
47
|
"chalk": "~4.1.2",
|
|
47
|
-
"chokidar": "~3.
|
|
48
|
+
"chokidar": "~3.6.0",
|
|
48
49
|
"cpx": "~1.5.0",
|
|
49
50
|
"css-loader": "~6.8.1",
|
|
50
51
|
"debug": "^4.3.4",
|
|
@@ -66,7 +67,7 @@
|
|
|
66
67
|
"less-plugin-npm-import": "~2.1.0",
|
|
67
68
|
"memfs": "~4.7.7",
|
|
68
69
|
"mini-css-extract-plugin": "~2.7.6",
|
|
69
|
-
"moment": "^2.
|
|
70
|
+
"moment": "^2.30.1",
|
|
70
71
|
"moment-locales-webpack-plugin": "~1.2.0",
|
|
71
72
|
"portfinder": "~1.0.32",
|
|
72
73
|
"prettier": "~2.7.1",
|
|
@@ -99,5 +100,5 @@
|
|
|
99
100
|
"cli": {
|
|
100
101
|
"webpack": false
|
|
101
102
|
},
|
|
102
|
-
"gitHead": "
|
|
103
|
+
"gitHead": "b9322f0b223f6c4539ff2e90d2c18ffa97d349da"
|
|
103
104
|
}
|
|
@@ -13,6 +13,7 @@ import {
|
|
|
13
13
|
isCustomStyleRules,
|
|
14
14
|
isExposeSharedDependencies,
|
|
15
15
|
isLegacy,
|
|
16
|
+
isLegacyRoot,
|
|
16
17
|
isStyleCheckDisabled,
|
|
17
18
|
isWebComponent,
|
|
18
19
|
} from '../get-configuration';
|
|
@@ -248,15 +249,26 @@ describe('[startup] Utils', () => {
|
|
|
248
249
|
{
|
|
249
250
|
fn: isWebComponent,
|
|
250
251
|
defaultValue: false,
|
|
251
|
-
trigger:
|
|
252
|
+
trigger: [
|
|
253
|
+
{ cli: { 'web-component': true } },
|
|
254
|
+
{ cli: { 'web-component': { legacyRoot: true } } },
|
|
255
|
+
{ cli: { 'web-component': { legacyRoot: false } } },
|
|
256
|
+
],
|
|
252
257
|
},
|
|
253
|
-
|
|
258
|
+
{
|
|
259
|
+
fn: isLegacyRoot,
|
|
260
|
+
defaultValue: false,
|
|
261
|
+
trigger: { cli: { 'web-component': { legacyRoot: true } } },
|
|
262
|
+
},
|
|
263
|
+
])('$fn.name', ({ fn, defaultValue, trigger: triggers }) => {
|
|
254
264
|
itReturns(fn, defaultValue);
|
|
255
265
|
|
|
256
|
-
|
|
257
|
-
|
|
266
|
+
[triggers].flat().forEach(trigger => {
|
|
267
|
+
describe(`when ${packageJson} contains ${JSON.stringify(trigger)}`, () => {
|
|
268
|
+
beforeEach(() => mockPackageJson(trigger));
|
|
258
269
|
|
|
259
|
-
|
|
270
|
+
itReturns(fn, !defaultValue);
|
|
271
|
+
});
|
|
260
272
|
});
|
|
261
273
|
});
|
|
262
274
|
|
|
@@ -57,11 +57,15 @@ export enum CommandName {
|
|
|
57
57
|
}
|
|
58
58
|
/* eslint-enable @typescript-eslint/naming-convention */
|
|
59
59
|
|
|
60
|
+
interface WebComponentOptions {
|
|
61
|
+
legacyRoot: boolean;
|
|
62
|
+
}
|
|
63
|
+
|
|
60
64
|
type Configuration = {
|
|
61
65
|
'legacy'?: boolean;
|
|
62
66
|
'lint'?: { eslint: ESLintConfiguration; stylelint: StylelintConfiguration };
|
|
63
67
|
'test'?: JestConfiguration;
|
|
64
|
-
'web-component'?: boolean;
|
|
68
|
+
'web-component'?: boolean | WebComponentOptions;
|
|
65
69
|
'webpack'?: false | WebpackConfiguration;
|
|
66
70
|
} & {
|
|
67
71
|
[key in CommandName]: NodeConfiguration;
|
|
@@ -75,38 +79,6 @@ export function getConfigurationSafe(location = './'): Configuration {
|
|
|
75
79
|
return readJsonSafe(path.join(location, 'package.json'))?.cli ?? {};
|
|
76
80
|
}
|
|
77
81
|
|
|
78
|
-
export function isBundle(location?: string) {
|
|
79
|
-
return getConfiguration(location).webpack !== false;
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
export function isCustomStyleRules() {
|
|
83
|
-
const configuration = getConfiguration();
|
|
84
|
-
|
|
85
|
-
if (typeof configuration.webpack !== 'object') {
|
|
86
|
-
return false;
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
return configuration.webpack['custom-style-rules'] === true;
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
export function isExposeSharedDependencies() {
|
|
93
|
-
const configuration = getConfiguration();
|
|
94
|
-
|
|
95
|
-
if (typeof configuration.webpack !== 'object') {
|
|
96
|
-
return false;
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
return configuration.webpack['expose-shared-dependencies'] === true;
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
function pick<T, K extends keyof T>(target: T, keys: readonly K[]) {
|
|
103
|
-
return Object.fromEntries(
|
|
104
|
-
keys
|
|
105
|
-
.filter(key => Object.prototype.hasOwnProperty.call(target, key))
|
|
106
|
-
.map(key => [key, target[key]])
|
|
107
|
-
) as Pick<T, K>;
|
|
108
|
-
}
|
|
109
|
-
|
|
110
82
|
export function getDevServerConfiguration() {
|
|
111
83
|
const configuration = getConfiguration();
|
|
112
84
|
|
|
@@ -130,24 +102,49 @@ export function getDevServerConfiguration() {
|
|
|
130
102
|
>;
|
|
131
103
|
}
|
|
132
104
|
|
|
133
|
-
export function isWebComponent() {
|
|
134
|
-
return getConfiguration()['web-component'] === true;
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
export function isLegacy(location?: string) {
|
|
138
|
-
return getConfiguration(location).legacy === true;
|
|
139
|
-
}
|
|
140
|
-
|
|
141
105
|
export function getESLintConfiguration() {
|
|
142
106
|
return getConfiguration().lint?.eslint ?? {};
|
|
143
107
|
}
|
|
144
108
|
|
|
109
|
+
export function getJestConfiguration() {
|
|
110
|
+
return getConfiguration().test ?? {};
|
|
111
|
+
}
|
|
112
|
+
|
|
145
113
|
export function getStylelintConfiguration() {
|
|
146
114
|
return getConfiguration().lint?.stylelint ?? {};
|
|
147
115
|
}
|
|
148
116
|
|
|
149
|
-
export function
|
|
150
|
-
return getConfiguration().
|
|
117
|
+
export function isBundle(location?: string) {
|
|
118
|
+
return getConfiguration(location).webpack !== false;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
export function isCustomStyleRules() {
|
|
122
|
+
const configuration = getConfiguration();
|
|
123
|
+
|
|
124
|
+
if (typeof configuration.webpack !== 'object') {
|
|
125
|
+
return false;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
return configuration.webpack['custom-style-rules'] === true;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
export function isExposeSharedDependencies() {
|
|
132
|
+
const configuration = getConfiguration();
|
|
133
|
+
|
|
134
|
+
if (typeof configuration.webpack !== 'object') {
|
|
135
|
+
return false;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
return configuration.webpack['expose-shared-dependencies'] === true;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
export function isLegacy(location?: string) {
|
|
142
|
+
return getConfiguration(location).legacy === true;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
export function isLegacyRoot() {
|
|
146
|
+
const config = getConfiguration()['web-component'];
|
|
147
|
+
return typeof config === 'object' && config.legacyRoot === true;
|
|
151
148
|
}
|
|
152
149
|
|
|
153
150
|
export function isStyleCheckDisabled() {
|
|
@@ -159,3 +156,17 @@ export function isStyleCheckDisabled() {
|
|
|
159
156
|
|
|
160
157
|
return configuration.webpack?.['disable-style-check'] === true;
|
|
161
158
|
}
|
|
159
|
+
|
|
160
|
+
export function isWebComponent() {
|
|
161
|
+
const config = getConfiguration()['web-component'];
|
|
162
|
+
return config === true || typeof config === 'object';
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
function pick<T extends object, K extends keyof T>(target: T, keys: readonly K[]) {
|
|
166
|
+
return keys.reduce((result, key) => {
|
|
167
|
+
if (Object.hasOwn(target, key)) {
|
|
168
|
+
result[key] = target[key];
|
|
169
|
+
}
|
|
170
|
+
return result;
|
|
171
|
+
}, {} as Pick<T, K>);
|
|
172
|
+
}
|
|
@@ -7,7 +7,14 @@ import WebpackAssetsManifest from 'webpack-assets-manifest';
|
|
|
7
7
|
import VirtualModulesPlugin from 'webpack-virtual-modules';
|
|
8
8
|
|
|
9
9
|
import { webpackDevConfigFileName, webpackProdConfigFileName } from '../../cli/utils';
|
|
10
|
-
import {
|
|
10
|
+
import {
|
|
11
|
+
getFolders,
|
|
12
|
+
getPackageData,
|
|
13
|
+
getPackages,
|
|
14
|
+
getTsConfig,
|
|
15
|
+
isLegacyRoot,
|
|
16
|
+
isWebComponent,
|
|
17
|
+
} from '../../utils';
|
|
11
18
|
import { webComponentStyleRules } from '../__mocks__';
|
|
12
19
|
import { generateMetadata } from '../configs/utils';
|
|
13
20
|
import { featureCohort, getCallerFile, splitByEntry } from '../utils';
|
|
@@ -33,6 +40,7 @@ jest.mock('../../utils', () => ({
|
|
|
33
40
|
getPackageData: jest.fn(),
|
|
34
41
|
getPackages: jest.fn(),
|
|
35
42
|
getTsConfig: jest.fn(),
|
|
43
|
+
isLegacyRoot: jest.fn(),
|
|
36
44
|
isWebComponent: jest.fn(),
|
|
37
45
|
}));
|
|
38
46
|
jest.mock('../configs/utils/generate-metadata');
|
|
@@ -56,12 +64,13 @@ describe(`[startup] ${createWebpackConfig.name}`, () => {
|
|
|
56
64
|
].join('\n');
|
|
57
65
|
|
|
58
66
|
const indexPath = () => path.join(process.cwd(), `${source}/index.ts`);
|
|
59
|
-
const indexCode =
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
67
|
+
const indexCode = ({ legacyRoot = false }: { legacyRoot?: boolean } = {}) =>
|
|
68
|
+
[
|
|
69
|
+
`import { register } from '@servicetitan/web-components';`,
|
|
70
|
+
`import { App } from './app';`,
|
|
71
|
+
`require('./design-system.css');`,
|
|
72
|
+
`register(App, false, { legacyRoot: ${legacyRoot} });`,
|
|
73
|
+
].join('\n');
|
|
65
74
|
|
|
66
75
|
let overrides: Parameters<typeof createWebpackConfig>[0];
|
|
67
76
|
let options: NonNullable<Parameters<typeof createWebpackConfig>[1]>;
|
|
@@ -86,6 +95,7 @@ describe(`[startup] ${createWebpackConfig.name}`, () => {
|
|
|
86
95
|
jest.mocked(getPackageData).mockReturnValue({ dependencies: {}, sharedDependencies: {} });
|
|
87
96
|
jest.mocked(getPackages).mockReturnValue([]);
|
|
88
97
|
jest.mocked(getTsConfig).mockReturnValue(tsConfig);
|
|
98
|
+
jest.mocked(isLegacyRoot).mockReturnValue(false);
|
|
89
99
|
|
|
90
100
|
vol.fromJSON({ [packageJson]: JSON.stringify({ name: packageName }) });
|
|
91
101
|
});
|
|
@@ -216,11 +226,24 @@ describe(`[startup] ${createWebpackConfig.name}`, () => {
|
|
|
216
226
|
expect(subject().plugins).toContainEqual(
|
|
217
227
|
new VirtualModulesPlugin({
|
|
218
228
|
[designSystemPath()]: designSystemCode,
|
|
219
|
-
[indexPath()]: indexCode,
|
|
229
|
+
[indexPath()]: indexCode(),
|
|
220
230
|
})
|
|
221
231
|
);
|
|
222
232
|
});
|
|
223
233
|
|
|
234
|
+
describe('with {legacyRoot: true}', () => {
|
|
235
|
+
beforeEach(() => jest.mocked(isLegacyRoot).mockReturnValue(true));
|
|
236
|
+
|
|
237
|
+
test('registers component with {legacyRoot: true}', () => {
|
|
238
|
+
expect(subject().plugins).toContainEqual(
|
|
239
|
+
new VirtualModulesPlugin({
|
|
240
|
+
[designSystemPath()]: designSystemCode,
|
|
241
|
+
[indexPath()]: indexCode({ legacyRoot: true }),
|
|
242
|
+
})
|
|
243
|
+
);
|
|
244
|
+
});
|
|
245
|
+
});
|
|
246
|
+
|
|
224
247
|
describe('when design-system.css exists', () => {
|
|
225
248
|
beforeEach(() => {
|
|
226
249
|
vol.fromJSON({
|
|
@@ -232,7 +255,7 @@ describe(`[startup] ${createWebpackConfig.name}`, () => {
|
|
|
232
255
|
test('omits design system virtual module', () => {
|
|
233
256
|
expect(subject().plugins).toContainEqual(
|
|
234
257
|
new VirtualModulesPlugin({
|
|
235
|
-
[indexPath()]: indexCode,
|
|
258
|
+
[indexPath()]: indexCode(),
|
|
236
259
|
})
|
|
237
260
|
);
|
|
238
261
|
});
|
|
@@ -245,9 +268,9 @@ describe(`[startup] ${createWebpackConfig.name}`, () => {
|
|
|
245
268
|
expect(subject().plugins).toContainEqual(
|
|
246
269
|
new VirtualModulesPlugin({
|
|
247
270
|
[designSystemPath()]: designSystemCode,
|
|
248
|
-
[indexPath()]: indexCode
|
|
271
|
+
[indexPath()]: indexCode()
|
|
249
272
|
.replace("require('./design-system.css');\n", '')
|
|
250
|
-
.replace('register(App, false
|
|
273
|
+
.replace('register(App, false', 'register(App, true'),
|
|
251
274
|
})
|
|
252
275
|
);
|
|
253
276
|
});
|
|
@@ -5,7 +5,7 @@ import { fs, vol } from 'memfs';
|
|
|
5
5
|
import MomentLocalesPlugin from 'moment-locales-webpack-plugin';
|
|
6
6
|
import os from 'os';
|
|
7
7
|
import path from 'path';
|
|
8
|
-
import { ProvidePlugin } from 'webpack';
|
|
8
|
+
import { IgnorePlugin, ProvidePlugin } from 'webpack';
|
|
9
9
|
const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
|
|
10
10
|
const FilterWarningsPlugin = require('webpack-filter-warnings-plugin');
|
|
11
11
|
import { argv } from 'yargs';
|
|
@@ -37,6 +37,7 @@ jest.mock('mini-css-extract-plugin', () =>
|
|
|
37
37
|
jest.mock('moment-locales-webpack-plugin', () => jest.fn());
|
|
38
38
|
jest.mock('webpack', () => ({
|
|
39
39
|
...jest.requireActual('webpack'),
|
|
40
|
+
IgnorePlugin: jest.fn(),
|
|
40
41
|
ProvidePlugin: jest.fn(),
|
|
41
42
|
}));
|
|
42
43
|
jest.mock('webpack-assets-manifest', () => jest.fn());
|
|
@@ -86,7 +87,8 @@ describe(`[startup] ${createWebpackConfig.name}`, () => {
|
|
|
86
87
|
}
|
|
87
88
|
|
|
88
89
|
function setOptions(props: typeof options) {
|
|
89
|
-
|
|
90
|
+
options ??= {};
|
|
91
|
+
Object.assign(options, props);
|
|
90
92
|
}
|
|
91
93
|
|
|
92
94
|
beforeEach(() => {
|
|
@@ -108,13 +110,14 @@ describe(`[startup] ${createWebpackConfig.name}`, () => {
|
|
|
108
110
|
mockPlugIn('ForkTsCheckerWebpackPlugin')
|
|
109
111
|
);
|
|
110
112
|
jest.mocked(HtmlWebpackPlugin).mockImplementation(mockPlugIn('HtmlWebpackPlugin'));
|
|
113
|
+
jest.mocked(IgnorePlugin).mockImplementation(mockPlugIn('IgnorePlugin'));
|
|
111
114
|
jest.mocked(MomentLocalesPlugin).mockImplementation(mockPlugIn('MomentLocalesPlugin'));
|
|
112
115
|
jest.mocked(ProvidePlugin).mockImplementation(mockPlugIn('ProvidePlugin'));
|
|
113
116
|
|
|
114
|
-
jest.mocked(getFolders).mockImplementation((location?: string) =>
|
|
115
|
-
|
|
116
|
-
destination
|
|
117
|
-
})
|
|
117
|
+
jest.mocked(getFolders).mockImplementation((location?: string) => {
|
|
118
|
+
const prefix = location ? `${location.replace(/\W/g, '')}-` : '';
|
|
119
|
+
return { source: `${prefix}${source}`, destination };
|
|
120
|
+
});
|
|
118
121
|
jest.mocked(getPackageData).mockReturnValue({ dependencies, sharedDependencies });
|
|
119
122
|
jest.mocked(getPackageDependencyVersion).mockImplementation(
|
|
120
123
|
(_, defaultVersion) => defaultVersion
|
|
@@ -313,8 +316,8 @@ describe(`[startup] ${createWebpackConfig.name}`, () => {
|
|
|
313
316
|
});
|
|
314
317
|
|
|
315
318
|
test('configures ".css" rule to exclude .module.css files', () => {
|
|
316
|
-
const cssRule: any = subject().module?.rules?.find(({ test }: { test: RegExp }) =>
|
|
317
|
-
'.css'
|
|
319
|
+
const cssRule: any = subject().module?.rules?.find(({ test: regexp }: { test: RegExp }) =>
|
|
320
|
+
regexp.test('.css')
|
|
318
321
|
);
|
|
319
322
|
expect(
|
|
320
323
|
['design-system.css', 'foo.module.css', 'foo.css'].filter(path => cssRule.exclude(path))
|
|
@@ -366,6 +369,12 @@ describe(`[startup] ${createWebpackConfig.name}`, () => {
|
|
|
366
369
|
);
|
|
367
370
|
});
|
|
368
371
|
|
|
372
|
+
test('configures IgnorePlugin plugin', () => {
|
|
373
|
+
expect(subject().plugins).toContainEqual(
|
|
374
|
+
new IgnorePlugin({ checkResource: expect.any(Function) })
|
|
375
|
+
);
|
|
376
|
+
});
|
|
377
|
+
|
|
369
378
|
describe('when buildStat option is set to true', () => {
|
|
370
379
|
beforeEach(() => {
|
|
371
380
|
setOptions({ buildStat: true });
|
|
@@ -450,7 +459,10 @@ describe(`[startup] ${createWebpackConfig.name}`, () => {
|
|
|
450
459
|
});
|
|
451
460
|
|
|
452
461
|
describe('when mode is "production"', () => {
|
|
453
|
-
beforeEach(() =>
|
|
462
|
+
beforeEach(() => {
|
|
463
|
+
overrides.configuration ??= {};
|
|
464
|
+
Object.assign(overrides.configuration, { mode: 'production' });
|
|
465
|
+
});
|
|
454
466
|
|
|
455
467
|
test('changes "devtool" to "source-map"', () => {
|
|
456
468
|
expect(subject().devtool).toEqual('source-map');
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { checkResource } from '../check-resource';
|
|
2
|
+
import { isOptionalPeerDependency } from '../is-optional-peer-dependency';
|
|
3
|
+
|
|
4
|
+
jest.mock('../is-optional-peer-dependency');
|
|
5
|
+
|
|
6
|
+
describe(`${checkResource.name}`, () => {
|
|
7
|
+
let context: string;
|
|
8
|
+
let resource: string;
|
|
9
|
+
|
|
10
|
+
const subject = () => checkResource(resource, context);
|
|
11
|
+
|
|
12
|
+
function itReturns(value: boolean) {
|
|
13
|
+
test(`returns ${value}`, () => expect(subject()).toBe(value));
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
describe('when resource is not an optional peer dependency', () => {
|
|
17
|
+
beforeEach(() => jest.mocked(isOptionalPeerDependency).mockReturnValue(false));
|
|
18
|
+
|
|
19
|
+
itReturns(false);
|
|
20
|
+
});
|
|
21
|
+
|
|
22
|
+
describe('when resource is optional peer dependency', () => {
|
|
23
|
+
beforeEach(() => jest.mocked(isOptionalPeerDependency).mockReturnValue(true));
|
|
24
|
+
|
|
25
|
+
describe('when resource is present', () => {
|
|
26
|
+
beforeEach(() => (resource = 'fs'));
|
|
27
|
+
|
|
28
|
+
itReturns(false);
|
|
29
|
+
});
|
|
30
|
+
|
|
31
|
+
describe('when resource is not present', () => {
|
|
32
|
+
beforeEach(() => (resource = 'foo'));
|
|
33
|
+
|
|
34
|
+
itReturns(true);
|
|
35
|
+
});
|
|
36
|
+
});
|
|
37
|
+
});
|
package/src/webpack/configs/plugins/ignore-plugin/__tests__/is-optional-peer-dependency.test.ts
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { isOptionalPeerDependency } from '../is-optional-peer-dependency';
|
|
2
|
+
|
|
3
|
+
describe(`${isOptionalPeerDependency.name}`, () => {
|
|
4
|
+
const subject = (...args: Parameters<typeof isOptionalPeerDependency>) =>
|
|
5
|
+
isOptionalPeerDependency(...args);
|
|
6
|
+
|
|
7
|
+
describe.each([
|
|
8
|
+
{
|
|
9
|
+
resource: 'react-dom/client',
|
|
10
|
+
contexts: ['@servicetitan/web-components', '@servicetitan/ko-bridge'],
|
|
11
|
+
},
|
|
12
|
+
])('with dependency "$resource"', ({ resource, contexts }) => {
|
|
13
|
+
contexts.forEach(context => {
|
|
14
|
+
test(`with context ${context}, returns true`, () => {
|
|
15
|
+
expect(subject({ context, resource })).toBe(true);
|
|
16
|
+
});
|
|
17
|
+
});
|
|
18
|
+
});
|
|
19
|
+
|
|
20
|
+
describe.each([
|
|
21
|
+
{ resource: 'react-dom', contexts: ['@servicetitan/web-components'] },
|
|
22
|
+
{ resource: 'react-dom/client', contexts: ['@servicetitan/foo'] },
|
|
23
|
+
])('with dependency "$resource"', ({ resource, contexts }) => {
|
|
24
|
+
contexts.forEach(context => {
|
|
25
|
+
test(`with context ${context}, returns false`, () => {
|
|
26
|
+
expect(subject({ context, resource })).toBe(false);
|
|
27
|
+
});
|
|
28
|
+
});
|
|
29
|
+
});
|
|
30
|
+
});
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { isOptionalPeerDependency } from './is-optional-peer-dependency';
|
|
2
|
+
|
|
3
|
+
export function checkResource(resource: string, context: string) {
|
|
4
|
+
if (isOptionalPeerDependency({ resource, context })) {
|
|
5
|
+
try {
|
|
6
|
+
require.resolve(resource);
|
|
7
|
+
} catch (e) {
|
|
8
|
+
return true;
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
return false;
|
|
12
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { IgnorePlugin } from 'webpack';
|
|
2
|
+
|
|
3
|
+
import { Context, Overrides } from '../../types';
|
|
4
|
+
import { checkResource } from './check-resource';
|
|
5
|
+
|
|
6
|
+
export function ignorePlugin(_context: Context, _: Overrides) {
|
|
7
|
+
/**
|
|
8
|
+
* Ignore optional peer dependencies
|
|
9
|
+
* @see {@link: file://./../../../../../../web-components/src/render.ts}
|
|
10
|
+
* @see {@link: file://./../../../../../../ko-bridge/src/ko-binding-handlers.tsx}
|
|
11
|
+
*/
|
|
12
|
+
return new IgnorePlugin({ checkResource });
|
|
13
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './ignore-plugin';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
interface Dependency {
|
|
2
|
+
context: string;
|
|
3
|
+
resource: string;
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
export function isOptionalPeerDependency({ context, resource }: Dependency) {
|
|
7
|
+
return (
|
|
8
|
+
resource === 'react-dom/client' && /@servicetitan\/(ko-bridge|web-components)/.test(context)
|
|
9
|
+
);
|
|
10
|
+
}
|
|
@@ -4,6 +4,7 @@ export * from './define-exposed-dependencies-plugin';
|
|
|
4
4
|
export * from './define-web-component-name-plugin';
|
|
5
5
|
export * from './filter-warnings-plugin';
|
|
6
6
|
export * from './html-plugin';
|
|
7
|
+
export * from './ignore-plugin';
|
|
7
8
|
export * from './mini-css-extract-plugin';
|
|
8
9
|
export * from './moment-locales-plugin';
|
|
9
10
|
export * from './provide-react-plugin';
|
|
@@ -31,12 +31,13 @@ function designSystemCode() {
|
|
|
31
31
|
].join('\n');
|
|
32
32
|
}
|
|
33
33
|
|
|
34
|
-
function indexCode({ embed }: Context) {
|
|
34
|
+
function indexCode({ embed, isLegacyRoot }: Context) {
|
|
35
|
+
const options = `{ legacyRoot: ${isLegacyRoot} }`;
|
|
35
36
|
return [
|
|
36
37
|
`import { register } from '@servicetitan/web-components';`,
|
|
37
38
|
`import { App } from './app';`,
|
|
38
39
|
...(embed
|
|
39
|
-
? [`register(App, true);`]
|
|
40
|
-
: [`require('./design-system.css');`, `register(App, false);`]),
|
|
40
|
+
? [`register(App, true, ${options});`]
|
|
41
|
+
: [`require('./design-system.css');`, `register(App, false, ${options});`]),
|
|
41
42
|
].join('\n');
|
|
42
43
|
}
|
|
@@ -6,6 +6,7 @@ import {
|
|
|
6
6
|
defineWebComponentNamePlugin,
|
|
7
7
|
filterWarningsPlugin,
|
|
8
8
|
htmlPlugin,
|
|
9
|
+
ignorePlugin,
|
|
9
10
|
miniCssExtractPlugin,
|
|
10
11
|
momentLocalesPlugin,
|
|
11
12
|
provideReactPlugin,
|
|
@@ -25,6 +26,7 @@ export function pluginsConfig(context: Context, overrides: Overrides): Result {
|
|
|
25
26
|
defineWebComponentNamePlugin,
|
|
26
27
|
filterWarningsPlugin,
|
|
27
28
|
htmlPlugin,
|
|
29
|
+
ignorePlugin,
|
|
28
30
|
miniCssExtractPlugin,
|
|
29
31
|
momentLocalesPlugin,
|
|
30
32
|
tsCheckerPlugin,
|
|
@@ -9,6 +9,7 @@ export interface Context extends Options {
|
|
|
9
9
|
experimentalBundlers: boolean;
|
|
10
10
|
isCustomStyleRules: boolean;
|
|
11
11
|
isExposeSharedDependencies: boolean;
|
|
12
|
+
isLegacyRoot: boolean;
|
|
12
13
|
isProduction: boolean;
|
|
13
14
|
isWebComponent: boolean;
|
|
14
15
|
packageData: ReturnType<typeof getPackageData>;
|
|
@@ -8,6 +8,7 @@ import {
|
|
|
8
8
|
getPackageData,
|
|
9
9
|
isCustomStyleRules,
|
|
10
10
|
isExposeSharedDependencies,
|
|
11
|
+
isLegacyRoot,
|
|
11
12
|
isWebComponent,
|
|
12
13
|
loadSharedDependencies,
|
|
13
14
|
log,
|
|
@@ -48,6 +49,7 @@ export function createWebpackConfig(overrides: Overrides, options: Options = {})
|
|
|
48
49
|
options.experimentalBundlers ?? !!(argv as Arguments)['experimental-bundlers'],
|
|
49
50
|
isCustomStyleRules: isCustomStyleRules(),
|
|
50
51
|
isExposeSharedDependencies: isExposeSharedDependencies(),
|
|
52
|
+
isLegacyRoot: isLegacyRoot(),
|
|
51
53
|
isProduction: configuration.mode === 'production',
|
|
52
54
|
isWebComponent: isWebComponent(),
|
|
53
55
|
name: '',
|
|
@@ -7,12 +7,12 @@
|
|
|
7
7
|
"typings": "./dist/index.d.ts",
|
|
8
8
|
"scripts": {},
|
|
9
9
|
"dependencies": {
|
|
10
|
-
"@servicetitan/design-system": "^
|
|
11
|
-
"@servicetitan/hash-browser-router": "^
|
|
12
|
-
"@servicetitan/link-item": "^
|
|
13
|
-
"@servicetitan/log-service": "^
|
|
14
|
-
"@servicetitan/react-ioc": "^
|
|
15
|
-
"@servicetitan/web-components": "^
|
|
10
|
+
"@servicetitan/design-system": "^13.4.3",
|
|
11
|
+
"@servicetitan/hash-browser-router": "^23.1.0",
|
|
12
|
+
"@servicetitan/link-item": "^25.9.0",
|
|
13
|
+
"@servicetitan/log-service": "^23.1.0",
|
|
14
|
+
"@servicetitan/react-ioc": "^23.1.0",
|
|
15
|
+
"@servicetitan/web-components": "^23.1.0",
|
|
16
16
|
"axios": "^0.27.2",
|
|
17
17
|
"feature-a": "^0.0.0",
|
|
18
18
|
"feature-b": "^0.0.0",
|
|
@@ -8,11 +8,11 @@
|
|
|
8
8
|
"scripts": {},
|
|
9
9
|
"dependencies": {
|
|
10
10
|
"@servicetitan/design-system": "^14.0.0",
|
|
11
|
-
"@servicetitan/hash-browser-router": "^
|
|
12
|
-
"@servicetitan/link-item": "^
|
|
13
|
-
"@servicetitan/log-service": "^
|
|
14
|
-
"@servicetitan/react-ioc": "^
|
|
15
|
-
"@servicetitan/web-components": "^
|
|
11
|
+
"@servicetitan/hash-browser-router": "^23.1.0",
|
|
12
|
+
"@servicetitan/link-item": "^25.9.0",
|
|
13
|
+
"@servicetitan/log-service": "^23.1.0",
|
|
14
|
+
"@servicetitan/react-ioc": "^23.1.0",
|
|
15
|
+
"@servicetitan/web-components": "^23.1.0",
|
|
16
16
|
"axios": "^0.27.2",
|
|
17
17
|
"feature-a": "^0.0.0",
|
|
18
18
|
"feature-b": "^0.0.0",
|