@donotdev/cli 0.0.6 → 0.0.7

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.
Files changed (82) hide show
  1. package/dependencies-matrix.json +25 -7
  2. package/dist/bin/commands/build.js +156 -158
  3. package/dist/bin/commands/bump.js +153 -153
  4. package/dist/bin/commands/cacheout.js +154 -154
  5. package/dist/bin/commands/create-app.js +184 -156
  6. package/dist/bin/commands/create-project.js +154 -154
  7. package/dist/bin/commands/deploy.js +470 -470
  8. package/dist/bin/commands/dev.js +155 -155
  9. package/dist/bin/commands/emu.js +155 -155
  10. package/dist/bin/commands/format.js +154 -154
  11. package/dist/bin/commands/lint.js +157 -154
  12. package/dist/bin/commands/preview.js +155 -155
  13. package/dist/bin/commands/sync-secrets.js +155 -155
  14. package/dist/bin/commands/wai.d.ts +11 -0
  15. package/dist/bin/commands/wai.d.ts.map +1 -0
  16. package/dist/bin/commands/wai.js +12 -0
  17. package/dist/bin/commands/wai.js.map +1 -0
  18. package/dist/bin/dndev.js +24 -8
  19. package/dist/bin/donotdev.js +24 -8
  20. package/dist/index.js +524 -497
  21. package/package.json +1 -1
  22. package/templates/app-demo/src/config/app.ts.example +12 -0
  23. package/templates/app-next/src/config/app.ts.example +75 -48
  24. package/templates/app-vite/index.html.example +71 -37
  25. package/templates/app-vite/src/config/app.ts.example +75 -47
  26. package/templates/app-vite/src/pages/FormPageExample.tsx.example +152 -0
  27. package/templates/app-vite/src/pages/HomePage.tsx.example +81 -134
  28. package/templates/app-vite/src/pages/ListPageExample.tsx.example +88 -0
  29. package/templates/functions-firebase/build.mjs.example +8 -1
  30. package/templates/functions-firebase/functions-firebase/build.mjs.example +8 -1
  31. package/templates/functions-firebase/functions-firebase/src/index.ts.example +19 -25
  32. package/templates/functions-firebase/functions.config.js.example +35 -0
  33. package/templates/root-consumer/entities/ExampleEntity.ts.example +223 -0
  34. package/templates/root-consumer/entities/demo.ts.example +562 -0
  35. package/templates/root-consumer/entities/index.ts.example +15 -0
  36. package/templates/root-consumer/guides/{AGENT_START_HERE.md.example → dndev/AGENT_START_HERE.md.example} +22 -0
  37. package/templates/root-consumer/guides/dndev/COMPONENTS_CRUD.md.example +231 -0
  38. package/templates/root-consumer/guides/{SETUP_AUTH.md.example → dndev/SETUP_AUTH.md.example} +30 -0
  39. package/templates/root-consumer/guides/dndev/SETUP_CRUD.md.example +473 -0
  40. package/templates/root-consumer/guides/dndev/SETUP_FUNCTIONS.md.example +116 -0
  41. package/templates/root-consumer/guides/wai-way/WAI_WAY_CLI.md.example +404 -0
  42. package/templates/root-consumer/guides/wai-way/agents/architect.md.example +78 -0
  43. package/templates/root-consumer/guides/wai-way/agents/builder.md.example +87 -0
  44. package/templates/root-consumer/guides/wai-way/agents/extractor.md.example +325 -0
  45. package/templates/root-consumer/guides/wai-way/agents/polisher.md.example +100 -0
  46. package/templates/root-consumer/guides/wai-way/blueprints/0_brainstorm.md.example +281 -0
  47. package/templates/root-consumer/guides/wai-way/blueprints/1_scaffold.md.example +77 -0
  48. package/templates/root-consumer/guides/wai-way/blueprints/2_entities.md.example +104 -0
  49. package/templates/root-consumer/guides/wai-way/blueprints/3_compose.md.example +124 -0
  50. package/templates/root-consumer/guides/wai-way/blueprints/4_configure.md.example +165 -0
  51. package/templates/root-consumer/guides/wai-way/context_map.json.example +95 -0
  52. package/templates/root-consumer/guides/wai-way/entity_patterns.md.example +840 -0
  53. package/templates/root-consumer/guides/wai-way/page_patterns.md.example +686 -0
  54. package/templates/root-consumer/guides/wai-way/presets_guide.md.example +217 -0
  55. package/templates/root-consumer/guides/wai-way/spec_template.md.example +312 -0
  56. package/templates/functions-firebase/functions-firebase/src/crud/createEntity.ts.example +0 -19
  57. package/templates/functions-firebase/functions-firebase/src/crud/deleteEntity.ts.example +0 -14
  58. package/templates/functions-firebase/functions-firebase/src/crud/getEntity.ts.example +0 -14
  59. package/templates/functions-firebase/functions-firebase/src/crud/index.ts.example +0 -12
  60. package/templates/functions-firebase/functions-firebase/src/crud/listEntities.ts.example +0 -14
  61. package/templates/functions-firebase/functions-firebase/src/crud/updateEntity.ts.example +0 -14
  62. package/templates/root-consumer/guides/COMPONENTS_CRUD.md.example +0 -70
  63. package/templates/root-consumer/guides/SETUP_CRUD.md.example +0 -1244
  64. package/templates/root-consumer/guides/SETUP_FUNCTIONS.md.example +0 -114
  65. /package/templates/root-consumer/guides/{COMPONENTS_ADV.md.example → dndev/COMPONENTS_ADV.md.example} +0 -0
  66. /package/templates/root-consumer/guides/{COMPONENTS_ATOMIC.md.example → dndev/COMPONENTS_ATOMIC.md.example} +0 -0
  67. /package/templates/root-consumer/guides/{COMPONENTS_UI.md.example → dndev/COMPONENTS_UI.md.example} +0 -0
  68. /package/templates/root-consumer/guides/{ENV_SETUP.md.example → dndev/ENV_SETUP.md.example} +0 -0
  69. /package/templates/root-consumer/guides/{INDEX.md.example → dndev/INDEX.md.example} +0 -0
  70. /package/templates/root-consumer/guides/{SETUP_APP_CONFIG.md.example → dndev/SETUP_APP_CONFIG.md.example} +0 -0
  71. /package/templates/root-consumer/guides/{SETUP_BILLING.md.example → dndev/SETUP_BILLING.md.example} +0 -0
  72. /package/templates/root-consumer/guides/{SETUP_I18N.md.example → dndev/SETUP_I18N.md.example} +0 -0
  73. /package/templates/root-consumer/guides/{SETUP_LAYOUTS.md.example → dndev/SETUP_LAYOUTS.md.example} +0 -0
  74. /package/templates/root-consumer/guides/{SETUP_OAUTH.md.example → dndev/SETUP_OAUTH.md.example} +0 -0
  75. /package/templates/root-consumer/guides/{SETUP_PAGES.md.example → dndev/SETUP_PAGES.md.example} +0 -0
  76. /package/templates/root-consumer/guides/{SETUP_PWA.md.example → dndev/SETUP_PWA.md.example} +0 -0
  77. /package/templates/root-consumer/guides/{SETUP_THEMES.md.example → dndev/SETUP_THEMES.md.example} +0 -0
  78. /package/templates/root-consumer/guides/{USE_ROUTING.md.example → dndev/USE_ROUTING.md.example} +0 -0
  79. /package/templates/root-consumer/guides/{advanced → dndev/advanced}/APP_CHECK.md.example +0 -0
  80. /package/templates/root-consumer/guides/{advanced → dndev/advanced}/COOKIE_REFERENCE.md.example +0 -0
  81. /package/templates/root-consumer/guides/{advanced → dndev/advanced}/EMULATORS.md.example +0 -0
  82. /package/templates/root-consumer/guides/{advanced → dndev/advanced}/VERSION_CONTROL.md.example +0 -0
@@ -848,155 +848,6 @@ var init_cli_output = __esm({
848
848
  }
849
849
  });
850
850
 
851
- // packages/core/config/constants.js
852
- function getPatternsFor(type, repoRoot = null) {
853
- const patterns = SCAN_PATTERNS[type];
854
- if (!patterns) {
855
- throw new Error(`Unknown pattern type: ${type}`);
856
- }
857
- if (repoRoot && patterns.framework) {
858
- return {
859
- ...patterns,
860
- framework: patterns.framework.map((pattern) => `${repoRoot}/${pattern}`)
861
- };
862
- }
863
- return patterns;
864
- }
865
- function getGlobOptionsFor(type) {
866
- return GLOB_OPTIONS[type] || GLOB_OPTIONS.base;
867
- }
868
- var I18N_PATHS, SCAN_PATTERNS, GLOB_OPTIONS;
869
- var init_constants = __esm({
870
- "packages/core/config/constants.js"() {
871
- "use strict";
872
- init_utils();
873
- I18N_PATHS = {
874
- // Monorepo source structure (locales at root, not in src/)
875
- SOURCE_ROOT: "packages/core/i18n",
876
- SOURCE_LOCALES: "packages/core/i18n/locales",
877
- SOURCE_EAGER: "packages/core/i18n/locales/eager",
878
- SOURCE_LAZY: "packages/core/i18n/locales/lazy",
879
- // Published structure (same as source - no flattening needed)
880
- PUBLISHED_ROOT: "i18n",
881
- PUBLISHED_LOCALES: "i18n/locales",
882
- PUBLISHED_EAGER: "i18n/locales/eager",
883
- PUBLISHED_LAZY: "i18n/locales/lazy"
884
- };
885
- SCAN_PATTERNS = {
886
- routes: {
887
- consumer: ["src/**/*Page.tsx", "src/pages/**/*Page.tsx"],
888
- exclude: [
889
- "**/node_modules/**",
890
- "**/dist/**",
891
- "**/build/**",
892
- "**/*.test.tsx",
893
- "**/*.stories.tsx"
894
- ],
895
- extensions: [".tsx"]
896
- },
897
- css: {
898
- consumer: ["src/**/*.css"],
899
- themes: ["src/**/*.css"],
900
- extensions: [".css", ".scss", ".sass"],
901
- framework: [
902
- "packages/ui/src/**/*.css",
903
- "packages/core/components/src/**/*.css",
904
- "packages/core/templates/src/**/*.css"
905
- ]
906
- },
907
- i18n: {
908
- eager: ["src/locales/*_*.json"],
909
- lazy: ["src/**/locales/*_*.json", "!src/locales/*_*.json"],
910
- framework: {
911
- eager: [`${I18N_PATHS.SOURCE_EAGER}/*_*.json`],
912
- lazy: [`${I18N_PATHS.SOURCE_LAZY}/*_*.json`]
913
- },
914
- extensions: [".json"]
915
- },
916
- assets: {
917
- consumer: ["public/**/*"],
918
- fallback: ["manifest.json"],
919
- modern: [
920
- "logo.svg",
921
- "favicon.svg",
922
- "apple-touch-icon.png",
923
- "android-chrome-192x192.png",
924
- "android-chrome-512x512.png"
925
- ],
926
- patterns: [
927
- "favicon.svg",
928
- "favicon.ico",
929
- "favicon-*.png",
930
- "logo.svg",
931
- "logo.png",
932
- "logo.webp",
933
- "logo.avif",
934
- "apple-touch-icon*.png",
935
- "android-chrome-*.png",
936
- "manifest.json"
937
- ],
938
- fonts: ["fonts/**/*.woff2", "fonts/**/*.woff", "fonts/**/*.ttf"],
939
- framework: ["packages/ui/assets/**/*"]
940
- },
941
- pwa: {
942
- consumer: [
943
- "public/manifest.json",
944
- "public/service-worker.js",
945
- "public/sw.js",
946
- "public/icon-192x192.png",
947
- "public/icon-512x512.png",
948
- "public/favicon.ico",
949
- "public/favicon.svg",
950
- "public/apple-touch-icon.png",
951
- "public/logo.svg"
952
- ],
953
- exclude: ["**/node_modules/**", "**/dist/**", "**/build/**"],
954
- extensions: [".json", ".js", ".png", ".svg", ".ico"],
955
- framework: ["packages/ui/assets/**/*"]
956
- },
957
- globalIgnore: [
958
- "**/node_modules/**",
959
- "**/dist/**",
960
- "**/build/**",
961
- "**/.git/**",
962
- "**/coverage/**",
963
- "**/test/**"
964
- ]
965
- };
966
- GLOB_OPTIONS = {
967
- base: {
968
- absolute: true,
969
- onlyFiles: true,
970
- ignore: SCAN_PATTERNS.globalIgnore
971
- },
972
- css: {
973
- absolute: true,
974
- onlyFiles: true,
975
- ignore: [...SCAN_PATTERNS.globalIgnore, "**/*.test.css"]
976
- },
977
- routes: {
978
- absolute: true,
979
- onlyFiles: true,
980
- ignore: [
981
- ...SCAN_PATTERNS.globalIgnore,
982
- "**/*.test.tsx",
983
- "**/*.stories.tsx"
984
- ]
985
- },
986
- i18n: {
987
- absolute: true,
988
- onlyFiles: true,
989
- ignore: SCAN_PATTERNS.globalIgnore
990
- },
991
- assets: {
992
- absolute: true,
993
- onlyFiles: true,
994
- ignore: SCAN_PATTERNS.globalIgnore
995
- }
996
- };
997
- }
998
- });
999
-
1000
851
  // node_modules/.bun/fast-glob@3.3.3/node_modules/fast-glob/out/utils/array.js
1001
852
  var require_array = __commonJS({
1002
853
  "node_modules/.bun/fast-glob@3.3.3/node_modules/fast-glob/out/utils/array.js"(exports) {
@@ -6581,7 +6432,157 @@ var require_out4 = __commonJS({
6581
6432
  }
6582
6433
  });
6583
6434
 
6435
+ // packages/core/config/constants.js
6436
+ function getPatternsFor(type, repoRoot = null) {
6437
+ const patterns = SCAN_PATTERNS[type];
6438
+ if (!patterns) {
6439
+ throw new Error(`Unknown pattern type: ${type}`);
6440
+ }
6441
+ if (repoRoot && patterns.framework) {
6442
+ return {
6443
+ ...patterns,
6444
+ framework: patterns.framework.map((pattern) => `${repoRoot}/${pattern}`)
6445
+ };
6446
+ }
6447
+ return patterns;
6448
+ }
6449
+ function getGlobOptionsFor(type) {
6450
+ return GLOB_OPTIONS[type] || GLOB_OPTIONS.base;
6451
+ }
6452
+ var I18N_PATHS, SCAN_PATTERNS, GLOB_OPTIONS;
6453
+ var init_constants = __esm({
6454
+ "packages/core/config/constants.js"() {
6455
+ "use strict";
6456
+ init_utils();
6457
+ I18N_PATHS = {
6458
+ // Monorepo source structure (locales at root, not in src/)
6459
+ SOURCE_ROOT: "packages/core/i18n",
6460
+ SOURCE_LOCALES: "packages/core/i18n/locales",
6461
+ SOURCE_EAGER: "packages/core/i18n/locales/eager",
6462
+ SOURCE_LAZY: "packages/core/i18n/locales/lazy",
6463
+ // Published structure (same as source - no flattening needed)
6464
+ PUBLISHED_ROOT: "i18n",
6465
+ PUBLISHED_LOCALES: "i18n/locales",
6466
+ PUBLISHED_EAGER: "i18n/locales/eager",
6467
+ PUBLISHED_LAZY: "i18n/locales/lazy"
6468
+ };
6469
+ SCAN_PATTERNS = {
6470
+ routes: {
6471
+ consumer: ["src/**/*Page.tsx", "src/pages/**/*Page.tsx"],
6472
+ exclude: [
6473
+ "**/node_modules/**",
6474
+ "**/dist/**",
6475
+ "**/build/**",
6476
+ "**/*.test.tsx",
6477
+ "**/*.stories.tsx"
6478
+ ],
6479
+ extensions: [".tsx"]
6480
+ },
6481
+ css: {
6482
+ consumer: ["src/**/*.css"],
6483
+ themes: ["src/**/*.css"],
6484
+ extensions: [".css", ".scss", ".sass"],
6485
+ framework: [
6486
+ "packages/ui/src/**/*.css",
6487
+ "packages/core/components/src/**/*.css",
6488
+ "packages/core/templates/src/**/*.css"
6489
+ ]
6490
+ },
6491
+ i18n: {
6492
+ eager: ["src/locales/*_*.json"],
6493
+ lazy: ["src/**/locales/*_*.json", "!src/locales/*_*.json"],
6494
+ framework: {
6495
+ eager: [`${I18N_PATHS.SOURCE_EAGER}/*_*.json`],
6496
+ lazy: [`${I18N_PATHS.SOURCE_LAZY}/*_*.json`]
6497
+ },
6498
+ extensions: [".json"]
6499
+ },
6500
+ assets: {
6501
+ consumer: ["public/**/*"],
6502
+ fallback: ["manifest.json"],
6503
+ modern: [
6504
+ "logo.svg",
6505
+ "favicon.svg",
6506
+ "apple-touch-icon.png",
6507
+ "android-chrome-192x192.png",
6508
+ "android-chrome-512x512.png"
6509
+ ],
6510
+ patterns: [
6511
+ "favicon.svg",
6512
+ "favicon.ico",
6513
+ "favicon-*.png",
6514
+ "logo.svg",
6515
+ "logo.png",
6516
+ "logo.webp",
6517
+ "logo.avif",
6518
+ "apple-touch-icon*.png",
6519
+ "android-chrome-*.png",
6520
+ "manifest.json"
6521
+ ],
6522
+ fonts: ["fonts/**/*.woff2", "fonts/**/*.woff", "fonts/**/*.ttf"],
6523
+ framework: ["packages/ui/assets/**/*"]
6524
+ },
6525
+ pwa: {
6526
+ consumer: [
6527
+ "public/manifest.json",
6528
+ "public/service-worker.js",
6529
+ "public/sw.js",
6530
+ "public/icon-192x192.png",
6531
+ "public/icon-512x512.png",
6532
+ "public/favicon.ico",
6533
+ "public/favicon.svg",
6534
+ "public/apple-touch-icon.png",
6535
+ "public/logo.svg"
6536
+ ],
6537
+ exclude: ["**/node_modules/**", "**/dist/**", "**/build/**"],
6538
+ extensions: [".json", ".js", ".png", ".svg", ".ico"],
6539
+ framework: ["packages/ui/assets/**/*"]
6540
+ },
6541
+ globalIgnore: [
6542
+ "**/node_modules/**",
6543
+ "**/dist/**",
6544
+ "**/build/**",
6545
+ "**/.git/**",
6546
+ "**/coverage/**",
6547
+ "**/test/**"
6548
+ ]
6549
+ };
6550
+ GLOB_OPTIONS = {
6551
+ base: {
6552
+ absolute: true,
6553
+ onlyFiles: true,
6554
+ ignore: SCAN_PATTERNS.globalIgnore
6555
+ },
6556
+ css: {
6557
+ absolute: true,
6558
+ onlyFiles: true,
6559
+ ignore: [...SCAN_PATTERNS.globalIgnore, "**/*.test.css"]
6560
+ },
6561
+ routes: {
6562
+ absolute: true,
6563
+ onlyFiles: true,
6564
+ ignore: [
6565
+ ...SCAN_PATTERNS.globalIgnore,
6566
+ "**/*.test.tsx",
6567
+ "**/*.stories.tsx"
6568
+ ]
6569
+ },
6570
+ i18n: {
6571
+ absolute: true,
6572
+ onlyFiles: true,
6573
+ ignore: SCAN_PATTERNS.globalIgnore
6574
+ },
6575
+ assets: {
6576
+ absolute: true,
6577
+ onlyFiles: true,
6578
+ ignore: SCAN_PATTERNS.globalIgnore
6579
+ }
6580
+ };
6581
+ }
6582
+ });
6583
+
6584
6584
  // packages/core/config/utils/PathResolver.ts
6585
+ import * as fs from "node:fs";
6585
6586
  import { createRequire } from "node:module";
6586
6587
  import {
6587
6588
  resolve,
@@ -6593,7 +6594,6 @@ import {
6593
6594
  extname
6594
6595
  } from "node:path";
6595
6596
  import { fileURLToPath } from "node:url";
6596
- import * as fs from "node:fs";
6597
6597
  function safeExecuteAsync(fn, message) {
6598
6598
  return fn().catch((error2) => {
6599
6599
  throw new Error(
@@ -6606,8 +6606,8 @@ var init_PathResolver = __esm({
6606
6606
  "packages/core/config/utils/PathResolver.ts"() {
6607
6607
  "use strict";
6608
6608
  init_utils();
6609
- init_constants();
6610
6609
  import_fast_glob = __toESM(require_out4(), 1);
6610
+ init_constants();
6611
6611
  constants = {
6612
6612
  getGlobOptionsFor: getGlobOptionsFor || void 0,
6613
6613
  SCAN_PATTERNS: SCAN_PATTERNS || void 0,
@@ -7729,11 +7729,11 @@ var init_pathResolver = __esm({
7729
7729
  });
7730
7730
 
7731
7731
  // packages/tooling/src/bundler/utils.ts
7732
+ import { Buffer as Buffer2 } from "node:buffer";
7732
7733
  import { createRequire as createRequire2 } from "node:module";
7733
- import { fileURLToPath as fileURLToPath2 } from "node:url";
7734
7734
  import { dirname as dirname3, resolve as resolve3 } from "node:path";
7735
- import { Buffer as Buffer2 } from "node:buffer";
7736
7735
  import process from "node:process";
7736
+ import { fileURLToPath as fileURLToPath2 } from "node:url";
7737
7737
  var require2, __filename, __dirname;
7738
7738
  var init_utils = __esm({
7739
7739
  "packages/tooling/src/bundler/utils.ts"() {
@@ -7766,7 +7766,6 @@ init_utils();
7766
7766
  // packages/tooling/src/utils/app-selector.ts
7767
7767
  init_utils();
7768
7768
  init_dist2();
7769
- init_cli_output();
7770
7769
 
7771
7770
  // packages/tooling/src/utils/app-detection.ts
7772
7771
  init_utils();
@@ -7854,6 +7853,7 @@ function analyzeApp(appPath, appName) {
7854
7853
  }
7855
7854
 
7856
7855
  // packages/tooling/src/utils/app-selector.ts
7856
+ init_cli_output();
7857
7857
  async function selectApp(projectRoot, appName) {
7858
7858
  const apps = detectApps(projectRoot);
7859
7859
  if (apps.length === 0) {
@@ -7954,8 +7954,8 @@ function createEmulatorEnv(appPath, framework = "vite", options) {
7954
7954
  // packages/tooling/src/apps/emu.ts
7955
7955
  init_utils();
7956
7956
  import { spawnSync, execSync } from "node:child_process";
7957
- init_errors();
7958
7957
  init_cli_output();
7958
+ init_errors();
7959
7959
  init_pathResolver();
7960
7960
  init_pathResolver();
7961
7961
  function discoverFirebaseProjectId(appPath) {