@form8ion/javascript 8.0.1 → 8.0.2
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/README.md +1 -1
- package/example.js +1 -1
- package/lib/index.js +20 -28
- package/lib/index.js.map +1 -1
- package/lib/index.mjs +20 -28
- package/lib/index.mjs.map +1 -1
- package/package.json +3 -3
package/lib/index.mjs
CHANGED
|
@@ -284,7 +284,6 @@ function predicate ({projectRoot}) {
|
|
|
284
284
|
}
|
|
285
285
|
|
|
286
286
|
async function scaffoldTypescript ({config, projectType, projectRoot, testFilenamePattern}) {
|
|
287
|
-
const eslintConfigs = ['typescript'];
|
|
288
287
|
const shareableTsConfigPackage = `${config.scope}/tsconfig`;
|
|
289
288
|
|
|
290
289
|
await writeConfigFile({
|
|
@@ -307,8 +306,7 @@ async function scaffoldTypescript ({config, projectType, projectRoot, testFilena
|
|
|
307
306
|
});
|
|
308
307
|
|
|
309
308
|
return {
|
|
310
|
-
eslint: {configs:
|
|
311
|
-
eslintConfigs,
|
|
309
|
+
eslint: {configs: ['typescript']},
|
|
312
310
|
devDependencies: ['typescript', shareableTsConfigPackage],
|
|
313
311
|
vcsIgnore: {files: ['tsconfig.tsbuildinfo']}
|
|
314
312
|
};
|
|
@@ -1125,7 +1123,6 @@ async function scaffoldPackageType ({
|
|
|
1125
1123
|
return deepmerge.all([
|
|
1126
1124
|
{
|
|
1127
1125
|
documentation: scaffoldPackageDocumentation({packageName, visibility, scope, packageManager}),
|
|
1128
|
-
eslintConfigs: [],
|
|
1129
1126
|
nextSteps: [
|
|
1130
1127
|
{summary: 'Add the appropriate `save` flag to the installation instructions in the README'},
|
|
1131
1128
|
{summary: 'Publish pre-release versions to npm until package is stable enough to publish v1.0.0'}
|
|
@@ -1156,7 +1153,6 @@ async function scaffoldApplicationType ({projectRoot}) {
|
|
|
1156
1153
|
devDependencies: ['rimraf'],
|
|
1157
1154
|
vcsIgnore: {files: ['.env'], directories: [`/${buildDirectory}/`]},
|
|
1158
1155
|
buildDirectory,
|
|
1159
|
-
eslintConfigs: [],
|
|
1160
1156
|
nextSteps: []
|
|
1161
1157
|
};
|
|
1162
1158
|
}
|
|
@@ -1167,7 +1163,6 @@ async function scaffoldMonorepoType ({projectRoot}) {
|
|
|
1167
1163
|
await mergeIntoExistingPackageJson({projectRoot, config: {private: true}});
|
|
1168
1164
|
|
|
1169
1165
|
return {
|
|
1170
|
-
eslintConfigs: [],
|
|
1171
1166
|
nextSteps: [{
|
|
1172
1167
|
summary: 'Add packages to your new monorepo',
|
|
1173
1168
|
description: 'Leverage [@form8ion/add-package-to-monorepo](https://npm.im/@form8ion/add-package-to-monorepo)'
|
|
@@ -1208,7 +1203,6 @@ async function scaffoldCliType ({packageName, visibility, projectRoot, dialect,
|
|
|
1208
1203
|
vcsIgnore: {files: [], directories: [`/${defaultBuildDirectory}/`]},
|
|
1209
1204
|
buildDirectory: defaultBuildDirectory,
|
|
1210
1205
|
badges: defineBadges(packageName, visibility),
|
|
1211
|
-
eslintConfigs: [],
|
|
1212
1206
|
nextSteps: []
|
|
1213
1207
|
}
|
|
1214
1208
|
);
|
|
@@ -1250,9 +1244,7 @@ async function scaffoldProjectType ({
|
|
|
1250
1244
|
case projectTypes.MONOREPO:
|
|
1251
1245
|
return scaffoldMonorepoType({projectRoot});
|
|
1252
1246
|
case 'Other':
|
|
1253
|
-
return {
|
|
1254
|
-
eslintConfigs: []
|
|
1255
|
-
};
|
|
1247
|
+
return {};
|
|
1256
1248
|
default:
|
|
1257
1249
|
throw new Error(`The project-type of ${projectType} is invalid`);
|
|
1258
1250
|
}
|
|
@@ -1493,7 +1485,7 @@ async function scaffolder (options) {
|
|
|
1493
1485
|
decisions,
|
|
1494
1486
|
pathWithinParent
|
|
1495
1487
|
});
|
|
1496
|
-
const [nodeVersion, npmResults, dialectResults, codeStyleResults
|
|
1488
|
+
const [nodeVersion, npmResults, dialectResults, codeStyleResults] = await Promise.all([
|
|
1497
1489
|
scaffoldNodeVersion({projectRoot, nodeVersionCategory}),
|
|
1498
1490
|
scaffoldNpmConfig({projectType, projectRoot, registries}),
|
|
1499
1491
|
scaffoldDialect({
|
|
@@ -1503,24 +1495,24 @@ async function scaffolder (options) {
|
|
|
1503
1495
|
projectType,
|
|
1504
1496
|
testFilenamePattern: verificationResults.testFilenamePattern
|
|
1505
1497
|
}),
|
|
1506
|
-
scaffoldCodeStyle({projectRoot, projectType, dialect, configs, vcs, configureLinting})
|
|
1507
|
-
scaffoldProjectTypePlugin({
|
|
1508
|
-
projectRoot,
|
|
1509
|
-
projectType,
|
|
1510
|
-
projectName,
|
|
1511
|
-
packageName,
|
|
1512
|
-
packageManager,
|
|
1513
|
-
scope,
|
|
1514
|
-
dialect,
|
|
1515
|
-
tests,
|
|
1516
|
-
decisions,
|
|
1517
|
-
plugins: {
|
|
1518
|
-
[projectTypes.PACKAGE]: packageTypes,
|
|
1519
|
-
[projectTypes.APPLICATION]: applicationTypes,
|
|
1520
|
-
[projectTypes.MONOREPO]: monorepoTypes
|
|
1521
|
-
}
|
|
1522
|
-
})
|
|
1498
|
+
scaffoldCodeStyle({projectRoot, projectType, dialect, configs, vcs, configureLinting})
|
|
1523
1499
|
]);
|
|
1500
|
+
const projectTypePluginResults = await scaffoldProjectTypePlugin({
|
|
1501
|
+
projectRoot,
|
|
1502
|
+
projectType,
|
|
1503
|
+
projectName,
|
|
1504
|
+
packageName,
|
|
1505
|
+
packageManager,
|
|
1506
|
+
scope,
|
|
1507
|
+
dialect,
|
|
1508
|
+
tests,
|
|
1509
|
+
decisions,
|
|
1510
|
+
plugins: {
|
|
1511
|
+
[projectTypes.PACKAGE]: packageTypes,
|
|
1512
|
+
[projectTypes.APPLICATION]: applicationTypes,
|
|
1513
|
+
[projectTypes.MONOREPO]: monorepoTypes
|
|
1514
|
+
}
|
|
1515
|
+
});
|
|
1524
1516
|
const mergedContributions = deepmerge.all([
|
|
1525
1517
|
...(await Promise.all([
|
|
1526
1518
|
scaffoldChoice(
|