create-mirta 0.3.4 → 0.4.3

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 (96) hide show
  1. package/dist/classic.mjs +120 -0
  2. package/dist/index.mjs +800 -690
  3. package/dist/mono.mjs +208 -0
  4. package/dist/resolver.mjs +843 -0
  5. package/locales/en-US.json +109 -0
  6. package/locales/ru-RU.json +109 -0
  7. package/package.json +25 -22
  8. package/templates/classic/starter/content/package.json +11 -0
  9. package/{dist/templates/config/typescript → templates/classic/starter/content}/tsconfig.json +0 -5
  10. package/{dist/templates/eslint/eslint.config.mjs.ejs → templates/classic/starter/features/eslint/eslint.config.mjs.tt} +11 -6
  11. package/{dist/templates/base/_env → templates/classic/starter/features/examples/_.env} +1 -1
  12. package/templates/classic/starter/features/examples/src/wb-rules/01-counter.ts +12 -0
  13. package/templates/classic/starter/features/examples/src/wb-rules-modules/counter.ts +42 -0
  14. package/templates/classic/starter/features/examples-vitest/tests/wb-rules-modules/counter.test.ts +56 -0
  15. package/templates/classic/starter/features/vitest/package.json +10 -0
  16. package/templates/classic/starter/features/vitest-eslint/package.json +5 -0
  17. package/templates/classic/starter/template.json +10 -0
  18. package/{dist/templates/config/store → templates/classic/store/content}/package.json +1 -1
  19. package/templates/classic/store/features/examples/src/wb-rules/01-counter.ts +13 -0
  20. package/templates/classic/store/features/examples/src/wb-rules/02-counter.ts +19 -0
  21. package/templates/classic/store/features/examples/src/wb-rules-modules/counter-store.ts +33 -0
  22. package/templates/classic/store/features/examples/src/wb-rules-modules/counter.ts +44 -0
  23. package/templates/classic/store/features/examples-vitest/tests/wb-rules-modules/counter.test.ts +49 -0
  24. package/templates/classic/store/template.json +14 -0
  25. package/templates/mono/core/content/package.json +6 -0
  26. package/templates/mono/core/content/pnpm-workspace.yaml +3 -0
  27. package/templates/mono/core/content/sites/.gitkeep +0 -0
  28. package/templates/mono/core/content/tsconfig.json +31 -0
  29. package/templates/mono/core/features/eslint/eslint.config.mjs.tt +126 -0
  30. package/templates/mono/core/features/vitest/package.json +10 -0
  31. package/templates/mono/core/template.json +5 -0
  32. package/templates/mono/package/features/package/packages/{{package}}/package.json.tt +25 -0
  33. package/templates/mono/package/features/package/packages/{{package}}/src/.gitkeep +0 -0
  34. package/templates/mono/package/features/package/packages/{{package}}/tsconfig.build.json +10 -0
  35. package/templates/mono/package/features/package/sites/{{package}}-demo/package.json.tt +19 -0
  36. package/templates/mono/package/features/package/sites/{{package}}-demo/src/wb-rules/.gitkeep +0 -0
  37. package/templates/mono/package/features/package/sites/{{package}}-demo/src/wb-rules-modules/.gitkeep +0 -0
  38. package/templates/mono/package/features/package/sites/{{package}}-demo/tsconfig.build.json +10 -0
  39. package/templates/mono/package/features/package-examples/packages/{{package}}/src/index.ts +2 -0
  40. package/templates/mono/package/features/package-examples/packages/{{package}}/src/thermostat.ts +99 -0
  41. package/templates/mono/package/features/package-examples/packages/{{package}}/src/types.ts +25 -0
  42. package/templates/mono/package/features/package-examples/sites/{{package}}-demo/src/wb-rules/01-thermo.ts.tt +11 -0
  43. package/templates/mono/package/features/package-examples-vitest/packages/{{package}}/tests/mirta-thermostat.test.ts +72 -0
  44. package/templates/mono/package/features/package-github/packages/{{package}}/package.json.tt +11 -0
  45. package/templates/mono/package/template.json +16 -0
  46. package/templates/mono/sites/content/mirta.config.json +37 -0
  47. package/templates/mono/sites/content/sites/home/package.json +17 -0
  48. package/templates/mono/sites/content/sites/home/src/wb-rules/.gitkeep +0 -0
  49. package/templates/mono/sites/content/sites/home/src/wb-rules-modules/.gitkeep +0 -0
  50. package/templates/mono/sites/content/sites/home-staging/package.json +17 -0
  51. package/templates/mono/sites/content/sites/home-staging/src/wb-rules/.gitkeep +0 -0
  52. package/templates/mono/sites/content/sites/home-staging/src/wb-rules-modules/.gitkeep +0 -0
  53. package/templates/mono/sites/template.json +9 -0
  54. package/{dist/templates/base/_editorconfig → templates/shared/base/content/_.editorconfig} +1 -1
  55. package/{dist/templates/base/_gitignore → templates/shared/base/content/_.gitignore} +1 -3
  56. package/templates/shared/base/content/_.node-version +1 -0
  57. package/{dist/templates/base/.vscode → templates/shared/base/content/_.vscode}/settings.json +12 -1
  58. package/templates/shared/base/content/package.json +22 -0
  59. package/templates/shared/base/features/connection/_.env.local.tt +1 -0
  60. package/templates/shared/base/features/connection/mirta.config.json +6 -0
  61. package/templates/shared/base/features/eslint/package.json +9 -0
  62. package/templates/shared/base/features/examples/mirta.config.json.tt +51 -0
  63. package/templates/shared/base/features/github/_.github/workflows/build.yml.tt +56 -0
  64. package/templates/shared/base/features/github-vitest/_.github/workflows/test.yml +30 -0
  65. package/templates/shared/base/template.json +16 -0
  66. package/dist/locales/en-US.json +0 -85
  67. package/dist/locales/ru-RU.json +0 -86
  68. package/dist/templates/base/package.json +0 -27
  69. package/dist/templates/base/rollup.config.mjs +0 -15
  70. package/dist/templates/config/typescript/package.json +0 -8
  71. package/dist/templates/config/vitest/package.json +0 -10
  72. package/dist/templates/config/vitest/tests/setup/dotenv.ts +0 -5
  73. package/dist/templates/config/vitest/tests/setup/mirta.ts +0 -41
  74. package/dist/templates/config/vitest/tests/tsconfig.json +0 -9
  75. package/dist/templates/config/vitest/vitest.config.ts +0 -37
  76. package/dist/templates/example/base/src/wb-rules/00-dotenv.ts +0 -52
  77. package/dist/templates/example/base/src/wb-rules/01-count.ts +0 -6
  78. package/dist/templates/example/base/src/wb-rules-modules/counter.ts +0 -14
  79. package/dist/templates/example/store/src/wb-rules/01-count.ts +0 -10
  80. package/dist/templates/example/store/src/wb-rules-modules/counter-store.ts +0 -7
  81. package/dist/templates/example/store/src/wb-rules-modules/counter.ts +0 -20
  82. package/dist/templates/example/vitest/base/tests/wb-rules-modules/counter.test.ts +0 -10
  83. package/dist/templates/example/vitest/store/tests/wb-rules-modules/counter-store.test.ts +0 -13
  84. /package/{dist/assets → assets}/logo.art +0 -0
  85. /package/{dist/templates/base → templates/classic/starter/content}/src/wb-rules/.gitkeep +0 -0
  86. /package/{dist/templates/base → templates/classic/starter/content}/src/wb-rules-modules/.gitkeep +0 -0
  87. /package/{dist/templates/base → templates/classic/starter/content}/types/env.d.ts +0 -0
  88. /package/{dist/templates/config → templates/classic/starter/features}/vitest/tests/wb-rules-modules/.gitkeep +0 -0
  89. /package/{dist/templates/config → templates/classic/starter/features}/vitest/tsconfig.json +0 -0
  90. /package/{dist/templates/base/_gitattributes → templates/shared/base/content/_.gitattributes} +0 -0
  91. /package/{dist/templates/base/_npmrc → templates/shared/base/content/_.npmrc} +0 -0
  92. /package/{dist/templates/base/.vscode → templates/shared/base/content/_.vscode}/extensions.json +0 -0
  93. /package/{dist/templates/base/.vscode → templates/shared/base/content/_.vscode}/tasks.json +0 -0
  94. /package/{dist/templates/config/eslint/.vscode → templates/shared/base/features/eslint/_.vscode}/extensions.json +0 -0
  95. /package/{dist/templates/config/eslint/.vscode → templates/shared/base/features/eslint/_.vscode}/settings.json +0 -0
  96. /package/{dist/templates/config/vitest/.vscode → templates/shared/base/features/vitest/_.vscode}/extensions.json +0 -0
@@ -1,7 +0,0 @@
1
- import { defineStore } from '@mirta/store'
2
-
3
- export const useCounterStore = defineStore('counter', {
4
- state: () => ({
5
- count: 0,
6
- }),
7
- })
@@ -1,20 +0,0 @@
1
- import { useCounterStore } from '#wbm/counter-store'
2
-
3
- const store = useCounterStore()
4
-
5
- export function useCounter() {
6
-
7
- return {
8
- get count() {
9
-
10
- return store.count
11
-
12
- },
13
- increment() {
14
-
15
- store.count += 1
16
-
17
- },
18
- }
19
-
20
- }
@@ -1,10 +0,0 @@
1
- import { useCounter } from '#wbm/counter'
2
-
3
- test('Expect counter to increment', () => {
4
-
5
- const counter = useCounter()
6
- counter.increment()
7
-
8
- expect(counter.count).toBe(1)
9
-
10
- })
@@ -1,13 +0,0 @@
1
- import { useCounterStore } from '#wbm/counter-store'
2
-
3
- test('Expect state is shared', () => {
4
-
5
- const storeA = useCounterStore()
6
- const storeB = useCounterStore()
7
-
8
- const value = 10
9
- storeA.count += value
10
-
11
- expect(storeB.count).toBe(value)
12
-
13
- })
File without changes