@storm-software/workspace-tools 1.45.2 → 1.46.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/README.md +32 -2
- package/index.js +5070 -3314
- package/meta.json +1 -1
- package/package.json +3 -3
- package/src/base/index.js +3606 -1311
- package/src/executors/design-tokens/executor.js +3073 -973
- package/src/executors/tsup/executor.js +4446 -3253
- package/src/executors/tsup-browser/executor.js +4457 -3264
- package/src/executors/tsup-neutral/executor.js +4457 -3264
- package/src/executors/tsup-node/executor.js +4457 -3264
- package/src/executors/typia/executor.js +2412 -312
- package/src/generators/browser-library/generator.js +3596 -1298
- package/src/generators/config-schema/generator.js +2481 -383
- package/src/generators/init/init.js +49 -49
- package/src/generators/neutral-library/generator.js +3596 -1298
- package/src/generators/node-library/generator.js +3596 -1298
- package/src/generators/preset/generator.js +2489 -389
- package/src/utils/index.js +21 -36
package/src/utils/index.js
CHANGED
|
@@ -22124,14 +22124,11 @@ var applyWorkspaceExecutorTokens = (option, tokenizerOptions) => {
|
|
|
22124
22124
|
if (tokenizerOptions.config) {
|
|
22125
22125
|
const configKeys = Object.keys(tokenizerOptions.config);
|
|
22126
22126
|
if (configKeys.some((configKey) => result.includes(`{${configKey}}`))) {
|
|
22127
|
-
|
|
22127
|
+
for (const configKey of configKeys) {
|
|
22128
22128
|
if (result.includes(`{${configKey}}`)) {
|
|
22129
|
-
result = result.replaceAll(
|
|
22130
|
-
`{${configKey}}`,
|
|
22131
|
-
tokenizerOptions.config[configKey]
|
|
22132
|
-
);
|
|
22129
|
+
result = result.replaceAll(`{${configKey}}`, tokenizerOptions.config[configKey]);
|
|
22133
22130
|
}
|
|
22134
|
-
}
|
|
22131
|
+
}
|
|
22135
22132
|
}
|
|
22136
22133
|
}
|
|
22137
22134
|
if (result.includes("{projectName}")) {
|
|
@@ -22159,14 +22156,11 @@ var applyWorkspaceGeneratorTokens = (option, tokenizerOptions) => {
|
|
|
22159
22156
|
if (tokenizerOptions.config) {
|
|
22160
22157
|
const configKeys = Object.keys(tokenizerOptions.config);
|
|
22161
22158
|
if (configKeys.some((configKey) => result.includes(`{${configKey}}`))) {
|
|
22162
|
-
|
|
22159
|
+
for (const configKey of configKeys) {
|
|
22163
22160
|
if (result.includes(`{${configKey}}`)) {
|
|
22164
|
-
result = result.replaceAll(
|
|
22165
|
-
`{${configKey}}`,
|
|
22166
|
-
tokenizerOptions.config[configKey]
|
|
22167
|
-
);
|
|
22161
|
+
result = result.replaceAll(`{${configKey}}`, tokenizerOptions.config[configKey]);
|
|
22168
22162
|
}
|
|
22169
|
-
}
|
|
22163
|
+
}
|
|
22170
22164
|
}
|
|
22171
22165
|
}
|
|
22172
22166
|
if (result.includes("{workspaceRoot}")) {
|
|
@@ -22178,29 +22172,22 @@ var applyWorkspaceGeneratorTokens = (option, tokenizerOptions) => {
|
|
|
22178
22172
|
return result;
|
|
22179
22173
|
};
|
|
22180
22174
|
var applyWorkspaceTokens = (options, config, tokenizerFn) => {
|
|
22181
|
-
|
|
22175
|
+
const result = options;
|
|
22182
22176
|
if (!result) {
|
|
22183
22177
|
return {};
|
|
22184
22178
|
}
|
|
22185
|
-
return Object.keys(options).reduce(
|
|
22186
|
-
(
|
|
22187
|
-
|
|
22188
|
-
|
|
22189
|
-
|
|
22190
|
-
|
|
22191
|
-
|
|
22192
|
-
|
|
22193
|
-
|
|
22194
|
-
|
|
22195
|
-
|
|
22196
|
-
|
|
22197
|
-
tokenizerFn
|
|
22198
|
-
);
|
|
22199
|
-
}
|
|
22200
|
-
return ret;
|
|
22201
|
-
},
|
|
22202
|
-
{}
|
|
22203
|
-
);
|
|
22179
|
+
return Object.keys(options).reduce((ret, option) => {
|
|
22180
|
+
if (typeof options[option] === "string") {
|
|
22181
|
+
ret[option] = tokenizerFn(options[option], config);
|
|
22182
|
+
} else if (Array.isArray(options[option])) {
|
|
22183
|
+
ret[option] = options[option].map(
|
|
22184
|
+
(item) => typeof item === "string" ? tokenizerFn(item, config) : item
|
|
22185
|
+
);
|
|
22186
|
+
} else if (typeof options[option] === "object") {
|
|
22187
|
+
ret[option] = applyWorkspaceTokens(options[option], config, tokenizerFn);
|
|
22188
|
+
}
|
|
22189
|
+
return ret;
|
|
22190
|
+
}, {});
|
|
22204
22191
|
};
|
|
22205
22192
|
|
|
22206
22193
|
// packages/workspace-tools/src/utils/file-path-utils.ts
|
|
@@ -22299,9 +22286,7 @@ ${commentStart} ----------------------------------------------------------------
|
|
|
22299
22286
|
|
|
22300
22287
|
// packages/workspace-tools/src/utils/get-project-configurations.ts
|
|
22301
22288
|
var import_retrieve_workspace_files = require("nx/src/project-graph/utils/retrieve-workspace-files");
|
|
22302
|
-
var getProjectConfigurations = () => (0, import_retrieve_workspace_files.retrieveProjectConfigurationsWithoutPluginInference)(
|
|
22303
|
-
getWorkspaceRoot()
|
|
22304
|
-
);
|
|
22289
|
+
var getProjectConfigurations = () => (0, import_retrieve_workspace_files.retrieveProjectConfigurationsWithoutPluginInference)(getWorkspaceRoot());
|
|
22305
22290
|
var getProjectConfiguration = (projectName) => getProjectConfigurations()?.[projectName];
|
|
22306
22291
|
|
|
22307
22292
|
// packages/workspace-tools/src/utils/get-project-deps.ts
|
|
@@ -22378,7 +22363,7 @@ var typescriptVersion = "~5.2.2";
|
|
|
22378
22363
|
var eslintVersion = "~8.53.0";
|
|
22379
22364
|
var lintStagedVersion = "15.0.2";
|
|
22380
22365
|
var semanticReleaseVersion = "22.0.7";
|
|
22381
|
-
var nxVersion = "^17.
|
|
22366
|
+
var nxVersion = "^17.2.8";
|
|
22382
22367
|
var nodeVersion = "18.17.1";
|
|
22383
22368
|
var pnpmVersion = "8.10.2";
|
|
22384
22369
|
|