@icebreakers/monorepo-templates 0.1.11 → 0.1.12

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/assets/AGENTS.md CHANGED
@@ -24,6 +24,7 @@ When a single code file exceeds 300 lines, treat it as a refactor signal and spl
24
24
  When splitting code, do not create suffix-based sibling files such as `xxx.config.ts` or `xxx.filter.ts` just to move logic around. Create a dedicated folder (for example `xxx/`) and place the split modules inside it with clear responsibilities.
25
25
 
26
26
  All generated code must pass ESLint checks, and all generated style files must pass Stylelint checks.
27
+ Generated Vue files or other SFC files that include style blocks are also required to pass Stylelint checks.
27
28
 
28
29
  ## Testing Guidelines
29
30
 
package/assets/gitignore CHANGED
@@ -35,4 +35,5 @@ yarn-error.log*
35
35
  dist
36
36
  vite.config.ts.timestamp-*.mjs
37
37
  config.ts.timestamp-*.mjs
38
- .vite-inspect
38
+ .vite-inspect
39
+ .playwright-cli
@@ -3,7 +3,7 @@
3
3
  "type": "module",
4
4
  "version": "0.0.0",
5
5
  "private": true,
6
- "packageManager": "pnpm@10.30.2",
6
+ "packageManager": "pnpm@10.31.0",
7
7
  "author": "ice breaker <hi@sonofmagic.top>",
8
8
  "repository": {
9
9
  "type": "git",
@@ -45,36 +45,36 @@
45
45
  "script:mirror": "monorepo mirror"
46
46
  },
47
47
  "devDependencies": {
48
- "@changesets/cli": "^2.29.8",
49
- "@commitlint/cli": "^20.4.2",
50
- "@icebreakers/changelog-github": "^0.2.0",
51
- "@icebreakers/commitlint-config": "^1.2.8",
52
- "@icebreakers/eslint-config": "^1.6.21",
48
+ "@changesets/cli": "^2.30.0",
49
+ "@commitlint/cli": "^20.4.3",
50
+ "@icebreakers/changelog-github": "^0.2.1",
51
+ "@icebreakers/commitlint-config": "^1.2.10",
52
+ "@icebreakers/eslint-config": "^1.6.25",
53
53
  "@icebreakers/monorepo": "workspace:*",
54
- "@icebreakers/stylelint-config": "^2.0.2",
54
+ "@icebreakers/stylelint-config": "^2.0.3",
55
55
  "@types/fs-extra": "^11.0.4",
56
- "@types/node": "^25.3.0",
56
+ "@types/node": "^25.3.5",
57
57
  "@types/semver": "^7.7.1",
58
58
  "@vitest/coverage-v8": "~4.0.18",
59
59
  "ci-info": "^4.4.0",
60
60
  "cross-env": "^10.1.0",
61
61
  "defu": "^6.1.4",
62
- "es-toolkit": "^1.44.0",
63
- "eslint": "^10.0.2",
62
+ "es-toolkit": "^1.45.1",
63
+ "eslint": "^10.0.3",
64
64
  "execa": "^9.6.1",
65
- "fs-extra": "^11.3.3",
65
+ "fs-extra": "^11.3.4",
66
66
  "husky": "^9.1.7",
67
- "lint-staged": "^16.2.7",
67
+ "lint-staged": "^16.3.2",
68
68
  "only-allow": "^1.2.2",
69
69
  "pathe": "^2.0.3",
70
70
  "pkg-types": "^2.3.0",
71
71
  "rimraf": "^6.1.3",
72
- "stylelint": "^17.3.0",
73
- "tsdown": "0.20.3",
72
+ "stylelint": "^17.4.0",
73
+ "tsdown": "0.21.1",
74
74
  "tslib": "^2.8.1",
75
75
  "tsup": "^8.5.1",
76
76
  "tsx": "^4.21.0",
77
- "turbo": "^2.8.10",
77
+ "turbo": "^2.8.14",
78
78
  "type-fest": "^5.4.4",
79
79
  "typescript": "^5.9.3",
80
80
  "unbuild": "^3.6.1",
package/dist/index.mjs CHANGED
@@ -7,7 +7,6 @@ import checkbox from "@inquirer/checkbox";
7
7
  import input from "@inquirer/input";
8
8
  import select from "@inquirer/select";
9
9
  import { Command, program } from "commander";
10
-
11
10
  //#region assets-data.mjs
12
11
  const coreAssetTargets = [
13
12
  ".changeset",
@@ -44,7 +43,6 @@ const assetTargets$1 = [...coreAssetTargets, ...extraAssetTargets];
44
43
  function getAssetTargets$1(core = false) {
45
44
  return core ? [...coreAssetTargets] : [...assetTargets$1];
46
45
  }
47
-
48
46
  //#endregion
49
47
  //#region template-data.mjs
50
48
  const templateChoices$1 = [
@@ -97,18 +95,17 @@ const templateChoices$1 = [
97
95
  target: "apps/cli"
98
96
  }
99
97
  ];
100
-
101
98
  //#endregion
102
99
  //#region src/paths.ts
103
100
  const packageDir = path$1.resolve(fileURLToPath(new URL("../", import.meta.url)));
104
101
  const templatesDir = path$1.join(packageDir, "templates");
105
102
  const assetsDir = path$1.join(packageDir, "assets");
106
103
  const skeletonDir = assetsDir;
107
-
108
104
  //#endregion
109
105
  //#region src/utils/gitignore.ts
110
106
  const publishBasename = "gitignore";
111
107
  const workspaceBasename = ".gitignore";
108
+ const normalizedPathPattern = /[\\/]/;
112
109
  function detectSeparator(input) {
113
110
  if (input.includes("\\") && !input.includes("/")) return "\\";
114
111
  return "/";
@@ -116,10 +113,10 @@ function detectSeparator(input) {
116
113
  function replaceBasename(input, from, to) {
117
114
  if (!input) return input;
118
115
  const separator = detectSeparator(input);
119
- const normalized = input.replace(/[\\/]/g, separator);
116
+ const normalized = input.replace(normalizedPathPattern, separator);
120
117
  const hasTrailingSeparator = normalized.endsWith(separator);
121
118
  const segments = normalized.split(separator);
122
- if (hasTrailingSeparator && segments[segments.length - 1] === "") segments.pop();
119
+ if (hasTrailingSeparator && segments.at(-1) === "") segments.pop();
123
120
  const lastIndex = segments.length - 1;
124
121
  if (lastIndex >= 0 && segments[lastIndex] === from) {
125
122
  segments[lastIndex] = to;
@@ -137,7 +134,6 @@ function toWorkspaceGitignorePath(input) {
137
134
  function isGitignoreFile(name) {
138
135
  return toPublishGitignorePath(name) !== name || toWorkspaceGitignorePath(name) !== name;
139
136
  }
140
-
141
137
  //#endregion
142
138
  //#region src/utils/template-filter.ts
143
139
  const skipDirs = new Set([
@@ -170,9 +166,9 @@ function shouldSkipTemplatePath(rootDir, targetPath) {
170
166
  function createTemplateCopyFilter(rootDir) {
171
167
  return (src) => !shouldSkipTemplatePath(rootDir, src);
172
168
  }
173
-
174
169
  //#endregion
175
170
  //#region src/prepare.ts
171
+ const huskySkippedEntryPattern = /[\\/]_$/;
176
172
  async function pathExists$1(targetPath) {
177
173
  try {
178
174
  await fs.access(targetPath);
@@ -232,7 +228,7 @@ async function copyAssets(repoRoot, overwriteExisting) {
232
228
  if (!await pathExists$1(from)) continue;
233
229
  const to = path$1.join(assetsDir, toPublishGitignorePath(target));
234
230
  const stats = await fs.stat(from);
235
- await copyEntry(from, to, overwriteExisting, target === ".husky" ? (src) => !/[\\/]_$/.test(src) : void 0);
231
+ await copyEntry(from, to, overwriteExisting, target === ".husky" ? (src) => !huskySkippedEntryPattern.test(src) : void 0);
236
232
  if (stats.isDirectory()) await renameGitignoreFiles(to);
237
233
  }
238
234
  }
@@ -255,7 +251,6 @@ async function prepareAssets(options = {}) {
255
251
  await copyAssets(repoRoot, overwriteExisting);
256
252
  await copyTemplates(repoRoot, overwriteExisting);
257
253
  }
258
-
259
254
  //#endregion
260
255
  //#region src/runtime-assets.ts
261
256
  const lockFileName = ".prepare-assets.lock";
@@ -319,7 +314,6 @@ async function ensureTemplateAssetsPrepared() {
319
314
  });
320
315
  await ensurePromise;
321
316
  }
322
-
323
317
  //#endregion
324
318
  //#region src/scaffold.ts
325
319
  async function isEmptyDir(dir) {
@@ -404,7 +398,6 @@ async function scaffoldWorkspace(options) {
404
398
  });
405
399
  }
406
400
  }
407
-
408
401
  //#endregion
409
402
  //#region src/utils/command.ts
410
403
  async function runCommand(command, args, options = {}) {
@@ -413,7 +406,6 @@ async function runCommand(command, args, options = {}) {
413
406
  ...options
414
407
  });
415
408
  }
416
-
417
409
  //#endregion
418
410
  //#region src/index.ts
419
411
  const templateChoices = templateChoices$1;
@@ -422,6 +414,5 @@ const getAssetTargets = getAssetTargets$1;
422
414
  const templateSourceMap = Object.fromEntries(templateChoices.map((item) => [item.key, item.source]));
423
415
  const templateTargetMap = Object.fromEntries(templateChoices.map((item) => [item.key, item.target]));
424
416
  const templateMap = templateSourceMap;
425
-
426
417
  //#endregion
427
- export { Command, assetTargets, assetsDir, checkbox, createTemplateCopyFilter, ensureTemplateAssetsPrepared, execaCommand, getAssetTargets, input, isGitignoreFile, packageDir, prepareAssets, program, runCommand, scaffoldTemplate, scaffoldWorkspace, select, shouldSkipTemplatePath, skeletonDir, templateChoices, templateMap, templateSourceMap, templateTargetMap, templatesDir, toPublishGitignorePath, toWorkspaceGitignorePath };
418
+ export { Command, assetTargets, assetsDir, checkbox, createTemplateCopyFilter, ensureTemplateAssetsPrepared, execaCommand, getAssetTargets, input, isGitignoreFile, packageDir, prepareAssets, program, runCommand, scaffoldTemplate, scaffoldWorkspace, select, shouldSkipTemplatePath, skeletonDir, templateChoices, templateMap, templateSourceMap, templateTargetMap, templatesDir, toPublishGitignorePath, toWorkspaceGitignorePath };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@icebreakers/monorepo-templates",
3
3
  "type": "module",
4
- "version": "0.1.11",
4
+ "version": "0.1.12",
5
5
  "description": "Template assets for icebreaker monorepo scaffolding",
6
6
  "author": "ice breaker <hi@sonofmagic.top>",
7
7
  "license": "MIT",
@@ -19,35 +19,35 @@
19
19
  "@tanstack/vue-query": "^5.92.9",
20
20
  "@tanstack/vue-query-devtools": "^6.1.5",
21
21
  "@tanstack/vue-table": "^8.21.3",
22
- "@tanstack/vue-virtual": "^3.13.19",
23
- "@trpc/client": "^11.10.0",
22
+ "@tanstack/vue-virtual": "^3.13.21",
23
+ "@trpc/client": "^11.12.0",
24
24
  "clsx": "^2.1.1",
25
25
  "pinia": "^3.0.4",
26
26
  "tailwind-merge": "^3.5.0",
27
27
  "tailwind-variants": "^3.2.2",
28
28
  "vue": "^3.5.29",
29
- "vue-i18n": "^11.2.8",
29
+ "vue-i18n": "^11.3.0",
30
30
  "vue-router": "^5.0.3"
31
31
  },
32
32
  "devDependencies": {
33
- "@cloudflare/vite-plugin": "^1.25.5",
34
- "@hono/node-server": "^1.19.9",
33
+ "@cloudflare/vite-plugin": "^1.26.1",
34
+ "@hono/node-server": "^1.19.11",
35
35
  "@hono/trpc-server": "^0.4.2",
36
36
  "@tailwindcss/vite": "^4.2.1",
37
- "@trpc/server": "^11.10.0",
37
+ "@trpc/server": "^11.12.0",
38
38
  "@vitejs/plugin-vue": "^6.0.4",
39
39
  "@vitejs/plugin-vue-jsx": "^5.1.4",
40
- "@vue/tsconfig": "^0.8.1",
40
+ "@vue/tsconfig": "^0.9.0",
41
41
  "consola": "^3.4.2",
42
- "hono": "^4.12.2",
42
+ "hono": "^4.12.5",
43
43
  "tailwindcss": "^4.2.1",
44
44
  "typescript": "~5.9.3",
45
45
  "unplugin-vue-router": "^0.19.2",
46
46
  "vite": "^7.3.1",
47
- "vite-plugin-vue-devtools": "^8.0.6",
47
+ "vite-plugin-vue-devtools": "^8.0.7",
48
48
  "vite-tsconfig-paths": "^6.1.1",
49
49
  "vue-tsc": "3.2.5",
50
- "wrangler": "^4.68.1",
50
+ "wrangler": "^4.71.0",
51
51
  "zod": "^4.3.6"
52
52
  }
53
53
  }
@@ -52,10 +52,10 @@
52
52
  "types": "./dist/index.d.ts"
53
53
  },
54
54
  "devDependencies": {
55
- "@hono/node-server": "^1.19.9",
55
+ "@hono/node-server": "^1.19.11",
56
56
  "consola": "^3.4.2",
57
- "hono": "^4.12.2",
58
- "wrangler": "^4.68.1",
57
+ "hono": "^4.12.5",
58
+ "wrangler": "^4.71.0",
59
59
  "zod": "^4.3.6"
60
60
  }
61
61
  }
@@ -1,3 +1,5 @@
1
+ const lowercaseLetterPattern = /[a-z]/g
2
+
1
3
  export function format(str: string) {
2
- return str.replaceAll(/[a-z]/g, s => s.toUpperCase())
4
+ return str.replaceAll(lowercaseLetterPattern, s => s.toUpperCase())
3
5
  }
@@ -46,7 +46,7 @@
46
46
  "devDependencies": {
47
47
  "@vitejs/plugin-vue": "^6.0.4",
48
48
  "@vue/test-utils": "^2.4.6",
49
- "@vue/tsconfig": "^0.8.1",
49
+ "@vue/tsconfig": "^0.9.0",
50
50
  "jsdom": "^28.1.0",
51
51
  "vite": "^7.3.1",
52
52
  "vite-plugin-dts": "^4.5.4",