@vef-framework/dev 1.0.64 → 1.0.66

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 (51) hide show
  1. package/es/cli.js +2 -287
  2. package/es/commitlint-config.js +2 -11
  3. package/es/config.js +2 -72
  4. package/es/constants.js +2 -14
  5. package/es/eslint-config.js +2 -431
  6. package/es/index.js +2 -6
  7. package/es/modules.d.js +1 -2
  8. package/es/plugin-app-config.js +2 -34
  9. package/es/plugin-conventional-config.js +2 -109
  10. package/es/plugin-eslint.js +2 -20
  11. package/es/plugin-html.js +2 -82
  12. package/es/plugin-icons.js +2 -17
  13. package/es/plugin-injection.js +2 -17
  14. package/es/plugin-inspect.js +2 -11
  15. package/es/plugin-react-swc.js +2 -10
  16. package/es/plugin-router.js +2 -43
  17. package/es/plugin-stylelint.js +2 -20
  18. package/es/plugin-svgr.js +2 -55
  19. package/es/plugin-tailwindcss.js +2 -23
  20. package/es/plugin-tsconfig-paths.js +2 -10
  21. package/es/plugin-visualizer.js +2 -12
  22. package/es/plugin-webfont.js +2 -11
  23. package/es/stylelint-config.js +2 -64
  24. package/es/tailwind-config.js +2 -392
  25. package/lib/cli.cjs +2 -289
  26. package/lib/commitlint-config.cjs +2 -15
  27. package/lib/config.cjs +2 -76
  28. package/lib/constants.cjs +2 -28
  29. package/lib/eslint-config.cjs +2 -435
  30. package/lib/index.cjs +2 -18
  31. package/lib/modules.d.cjs +2 -4
  32. package/lib/plugin-app-config.cjs +2 -38
  33. package/lib/plugin-conventional-config.cjs +2 -113
  34. package/lib/plugin-eslint.cjs +2 -24
  35. package/lib/plugin-html.cjs +2 -86
  36. package/lib/plugin-icons.cjs +2 -22
  37. package/lib/plugin-injection.cjs +2 -21
  38. package/lib/plugin-inspect.cjs +2 -15
  39. package/lib/plugin-react-swc.cjs +2 -14
  40. package/lib/plugin-router.cjs +2 -47
  41. package/lib/plugin-stylelint.cjs +2 -24
  42. package/lib/plugin-svgr.cjs +2 -59
  43. package/lib/plugin-tailwindcss.cjs +2 -27
  44. package/lib/plugin-tsconfig-paths.cjs +2 -14
  45. package/lib/plugin-visualizer.cjs +2 -16
  46. package/lib/plugin-webfont.cjs +2 -15
  47. package/lib/stylelint-config.cjs +2 -68
  48. package/lib/tailwind-config.cjs +2 -396
  49. package/lib/types.cjs +2 -4
  50. package/package.json +1 -1
  51. package/template/package.json +5 -5
@@ -1,432 +1,3 @@
1
- /*! VefFramework version: 1.0.64, build time: 2025-01-10T01:26:01.941Z, made by Venus. */
2
- import { antfu } from '@antfu/eslint-config';
3
- import pluginRouter from '@tanstack/eslint-plugin-router';
4
- import pluginTailwind from 'eslint-plugin-tailwindcss';
5
-
6
- function defineEslintConfig() {
7
- return antfu(
8
- {
9
- ignores: [
10
- "**/node_modules",
11
- "**/dist",
12
- "**/public"
13
- ],
14
- stylistic: {
15
- indent: 2,
16
- jsx: true,
17
- quotes: "double",
18
- semi: true,
19
- overrides: {
20
- "style/line-comment-position": [
21
- "error",
22
- {
23
- position: "above"
24
- }
25
- ],
26
- "style/jsx-self-closing-comp": [
27
- "error",
28
- {
29
- component: true,
30
- html: true
31
- }
32
- ],
33
- "style/jsx-newline": [
34
- "error",
35
- {
36
- prevent: true,
37
- allowMultilines: true
38
- }
39
- ],
40
- "style/jsx-props-no-multi-spaces": "error",
41
- "style/jsx-sort-props": [
42
- "error",
43
- {
44
- callbacksLast: true,
45
- shorthandFirst: true,
46
- shorthandLast: false,
47
- multiline: "last",
48
- ignoreCase: true,
49
- noSortAlphabetically: false,
50
- reservedFirst: ["key", "ref"]
51
- }
52
- ],
53
- "style/newline-per-chained-call": [
54
- "error",
55
- {
56
- ignoreChainWithDepth: 3
57
- }
58
- ],
59
- "style/object-property-newline": "error",
60
- "style/brace-style": [
61
- "error",
62
- "1tbs"
63
- ],
64
- "style/arrow-parens": [
65
- "error",
66
- "as-needed"
67
- ],
68
- "style/multiline-comment-style": [
69
- "error",
70
- "starred-block"
71
- ],
72
- "style/implicit-arrow-linebreak": [
73
- "error",
74
- "beside"
75
- ],
76
- "style/no-extra-semi": "error",
77
- "style/array-element-newline": [
78
- "error",
79
- {
80
- consistent: true,
81
- multiline: true,
82
- minItems: 7
83
- }
84
- ],
85
- "style/function-call-argument-newline": [
86
- "error",
87
- "consistent"
88
- ],
89
- "style/padding-line-between-statements": [
90
- "error",
91
- {
92
- blankLine: "always",
93
- prev: "*",
94
- next: [
95
- "block",
96
- "multiline-block-like",
97
- "type",
98
- "interface",
99
- "enum",
100
- "function",
101
- "function-overload"
102
- ]
103
- },
104
- {
105
- blankLine: "always",
106
- prev: [
107
- "block",
108
- "multiline-block-like",
109
- "type",
110
- "interface",
111
- "enum",
112
- "function",
113
- "function-overload"
114
- ],
115
- next: "*"
116
- }
117
- ],
118
- "style/jsx-pascal-case": [
119
- "error",
120
- {
121
- allowAllCaps: false,
122
- allowLeadingUnderscore: false,
123
- allowNamespace: false,
124
- ignore: []
125
- }
126
- ],
127
- "style/switch-colon-spacing": [
128
- "error",
129
- {
130
- before: false,
131
- after: true
132
- }
133
- ],
134
- "style/object-curly-newline": [
135
- "error",
136
- {
137
- ObjectExpression: {
138
- multiline: true,
139
- consistent: true,
140
- minProperties: 3
141
- },
142
- ObjectPattern: {
143
- multiline: true,
144
- consistent: true,
145
- minProperties: 3
146
- },
147
- ImportDeclaration: {
148
- consistent: true,
149
- multiline: true
150
- },
151
- ExportDeclaration: {
152
- consistent: true,
153
- multiline: true
154
- }
155
- }
156
- ],
157
- "style/no-extra-parens": [
158
- "error",
159
- "all",
160
- {
161
- nestedBinaryExpressions: false,
162
- ternaryOperandBinaryExpressions: false,
163
- ignoreJSX: "multi-line"
164
- }
165
- ]
166
- }
167
- },
168
- javascript: {
169
- overrides: {
170
- "no-duplicate-imports": [
171
- "error",
172
- {
173
- includeExports: true
174
- }
175
- ],
176
- "prefer-object-spread": "error",
177
- "func-style": [
178
- "error",
179
- "declaration",
180
- {
181
- allowArrowFunctions: true
182
- }
183
- ],
184
- "curly": [
185
- "error",
186
- "all"
187
- ],
188
- "no-useless-escape": "error",
189
- "no-useless-concat": "error",
190
- "no-unused-private-class-members": "error",
191
- "no-unsafe-optional-chaining": "error",
192
- "no-dupe-else-if": "error",
193
- "no-eq-null": "error",
194
- "no-extra-label": "error",
195
- "no-negated-condition": "error",
196
- "no-invalid-this": "error",
197
- "arrow-body-style": [
198
- "error",
199
- "as-needed"
200
- ],
201
- "prefer-object-has-own": "error",
202
- "prefer-numeric-literals": "error",
203
- "prefer-named-capture-group": "error",
204
- "prefer-destructuring": "error",
205
- "object-shorthand": "error",
206
- "require-atomic-updates": "error",
207
- "require-await": "error",
208
- "camelcase": [
209
- "error",
210
- {
211
- properties: "always",
212
- ignoreGlobals: true
213
- }
214
- ],
215
- "no-promise-executor-return": [
216
- "error",
217
- {
218
- allowVoid: true
219
- }
220
- ],
221
- "sort-imports": "off",
222
- "no-console": "off"
223
- }
224
- },
225
- typescript: {
226
- overrides: {
227
- "ts/no-unused-expressions": [
228
- "error",
229
- {
230
- enforceForJSX: true
231
- }
232
- ],
233
- "ts/no-unused-vars": [
234
- "error",
235
- {
236
- args: "after-used",
237
- caughtErrors: "all",
238
- destructuredArrayIgnorePattern: "^_",
239
- ignoreRestSiblings: true
240
- }
241
- ],
242
- "ts/array-type": [
243
- "error",
244
- {
245
- default: "array-simple",
246
- readonly: "array-simple"
247
- }
248
- ],
249
- "ts/consistent-type-assertions": [
250
- "error",
251
- {
252
- assertionStyle: "as",
253
- objectLiteralTypeAssertions: "allow"
254
- }
255
- ],
256
- "ts/consistent-type-definitions": [
257
- "error",
258
- "interface"
259
- ],
260
- "ts/max-params": [
261
- "error",
262
- {
263
- max: 5
264
- }
265
- ]
266
- }
267
- },
268
- react: {
269
- overrides: {
270
- "react-naming-convention/component-name": ["error", "PascalCase"],
271
- "react-naming-convention/filename-extension": [
272
- "error",
273
- {
274
- allow: "as-needed",
275
- extensions: [".tsx"]
276
- }
277
- ],
278
- "react-hooks-extra/no-redundant-custom-hook": "error",
279
- "react-hooks-extra/no-unnecessary-use-memo": "error",
280
- "react-hooks-extra/no-unnecessary-use-callback": "error",
281
- "react-naming-convention/use-state": "error",
282
- "react-refresh/only-export-components": "error",
283
- "react-hooks/exhaustive-deps": [
284
- "error",
285
- {
286
- additionalHooks: "^use(Deep|Shallow)"
287
- }
288
- ],
289
- "react/no-clone-element": "off",
290
- "react/no-class-component": "error",
291
- "react/no-children-prop": "off",
292
- "react/no-children-to-array": "off",
293
- "react/no-children-for-each": "off",
294
- "react/no-children-count": "off"
295
- }
296
- },
297
- vue: false,
298
- jsx: true,
299
- regexp: true,
300
- jsonc: true,
301
- yaml: true,
302
- toml: true,
303
- markdown: {
304
- overrides: {
305
- "markdown/fenced-code-language": "error",
306
- "markdown/no-duplicate-headings": "error",
307
- "markdown/no-empty-links": "error"
308
- }
309
- },
310
- test: true,
311
- formatters: {
312
- markdown: "prettier",
313
- prettierOptions: {
314
- singleQuote: false,
315
- semi: true,
316
- tabWidth: 2,
317
- useTabs: false,
318
- trailingComma: "all",
319
- endOfLine: "lf",
320
- printWidth: 160,
321
- proseWrap: "never",
322
- arrowParens: "avoid",
323
- htmlWhitespaceSensitivity: "strict",
324
- bracketSameLine: true,
325
- bracketSpacing: true,
326
- quoteProps: "as-needed",
327
- jsxSingleQuote: false,
328
- singleAttributePerLine: false
329
- }
330
- }
331
- },
332
- {
333
- rules: {
334
- "unicorn/filename-case": [
335
- "error",
336
- {
337
- case: "kebabCase",
338
- ignore: ["README.md"]
339
- }
340
- ],
341
- "unicorn/prefer-date-now": "error",
342
- "unicorn/prefer-string-trim-start-end": "error",
343
- "unicorn/prefer-string-raw": "error",
344
- "unicorn/prefer-object-from-entries": "error",
345
- "unicorn/prefer-default-parameters": "error",
346
- "unicorn/prefer-array-find": "error",
347
- "unicorn/prefer-array-flat": "error",
348
- "unicorn/prefer-array-flat-map": "error",
349
- "unicorn/prefer-array-index-of": "error",
350
- "unicorn/prefer-array-some": "error",
351
- "unicorn/prefer-logical-operator-over-ternary": "error",
352
- "unicorn/no-array-push-push": "error",
353
- "unicorn/no-empty-file": "error",
354
- "unicorn/no-array-for-each": "error",
355
- "unicorn/no-for-loop": "error",
356
- "unicorn/no-unnecessary-await": "error",
357
- "unicorn/no-unnecessary-polyfills": "error",
358
- "unicorn/no-useless-undefined": "error",
359
- "unicorn/no-useless-switch-case": "error",
360
- "unicorn/no-useless-spread": "error",
361
- "unicorn/no-console-spaces": "error",
362
- "unicorn/no-unused-properties": "error",
363
- "unicorn/no-useless-promise-resolve-reject": "error",
364
- "import/order": "off",
365
- "import/first": "error",
366
- "import/export": "error",
367
- "import/no-named-as-default": "off",
368
- "import/no-named-default": "off",
369
- "perfectionist/sort-imports": [
370
- "error",
371
- {
372
- type: "natural"
373
- }
374
- ],
375
- "perfectionist/sort-exports": [
376
- "error",
377
- {
378
- type: "natural"
379
- }
380
- ],
381
- "perfectionist/sort-named-imports": [
382
- "error",
383
- {
384
- type: "natural",
385
- groupKind: "values-first"
386
- }
387
- ],
388
- "perfectionist/sort-named-exports": [
389
- "error",
390
- {
391
- type: "natural",
392
- groupKind: "values-first"
393
- }
394
- ],
395
- "eslint-comments/no-unlimited-disable": "off"
396
- }
397
- },
398
- {
399
- ignores: ["**/*.md", "**/*.md/*.{ts,tsx}", "**/src/pages/__root.{ts,tsx}"],
400
- rules: {
401
- "react-naming-convention/filename": [
402
- "error",
403
- {
404
- rule: "kebab-case"
405
- }
406
- ]
407
- }
408
- },
409
- ...pluginTailwind.configs["flat/recommended"],
410
- {
411
- rules: {
412
- "tailwindcss/migration-from-tailwind-2": "off",
413
- "tailwindcss/no-arbitrary-value": "off",
414
- "tailwindcss/classnames-order": "error",
415
- "tailwindcss/enforces-negative-arbitrary-values": "error",
416
- "tailwindcss/enforces-shorthand": "error",
417
- "tailwindcss/no-custom-classname": [
418
- "error",
419
- {
420
- whitelist: ["vef-.*"]
421
- }
422
- ],
423
- "tailwindcss/no-contradicting-classname": "error",
424
- "tailwindcss/no-unnecessary-arbitrary-value": "error"
425
- }
426
- },
427
- ...pluginRouter.configs["flat/recommended"]
428
- );
429
- }
430
-
431
- export { defineEslintConfig };
1
+ /*! VefFramework version: 1.0.66, build time: 2025-01-10T02:50:17.453Z, made by Venus. */
2
+ import{antfu as r}from"@antfu/eslint-config";import e from"@tanstack/eslint-plugin-router";import o from"eslint-plugin-tailwindcss";function defineEslintConfig(){return r({ignores:["**/node_modules","**/dist","**/public"],stylistic:{indent:2,jsx:!0,quotes:"double",semi:!0,overrides:{"style/line-comment-position":["error",{position:"above"}],"style/jsx-self-closing-comp":["error",{component:!0,html:!0}],"style/jsx-newline":["error",{prevent:!0,allowMultilines:!0}],"style/jsx-props-no-multi-spaces":"error","style/jsx-sort-props":["error",{callbacksLast:!0,shorthandFirst:!0,shorthandLast:!1,multiline:"last",ignoreCase:!0,noSortAlphabetically:!1,reservedFirst:["key","ref"]}],"style/newline-per-chained-call":["error",{ignoreChainWithDepth:3}],"style/object-property-newline":"error","style/brace-style":["error","1tbs"],"style/arrow-parens":["error","as-needed"],"style/multiline-comment-style":["error","starred-block"],"style/implicit-arrow-linebreak":["error","beside"],"style/no-extra-semi":"error","style/array-element-newline":["error",{consistent:!0,multiline:!0,minItems:7}],"style/function-call-argument-newline":["error","consistent"],"style/padding-line-between-statements":["error",{blankLine:"always",prev:"*",next:["block","multiline-block-like","type","interface","enum","function","function-overload"]},{blankLine:"always",prev:["block","multiline-block-like","type","interface","enum","function","function-overload"],next:"*"}],"style/jsx-pascal-case":["error",{allowAllCaps:!1,allowLeadingUnderscore:!1,allowNamespace:!1,ignore:[]}],"style/switch-colon-spacing":["error",{before:!1,after:!0}],"style/object-curly-newline":["error",{ObjectExpression:{multiline:!0,consistent:!0,minProperties:3},ObjectPattern:{multiline:!0,consistent:!0,minProperties:3},ImportDeclaration:{consistent:!0,multiline:!0},ExportDeclaration:{consistent:!0,multiline:!0}}],"style/no-extra-parens":["error","all",{nestedBinaryExpressions:!1,ternaryOperandBinaryExpressions:!1,ignoreJSX:"multi-line"}]}},javascript:{overrides:{"no-duplicate-imports":["error",{includeExports:!0}],"prefer-object-spread":"error","func-style":["error","declaration",{allowArrowFunctions:!0}],curly:["error","all"],"no-useless-escape":"error","no-useless-concat":"error","no-unused-private-class-members":"error","no-unsafe-optional-chaining":"error","no-dupe-else-if":"error","no-eq-null":"error","no-extra-label":"error","no-negated-condition":"error","no-invalid-this":"error","arrow-body-style":["error","as-needed"],"prefer-object-has-own":"error","prefer-numeric-literals":"error","prefer-named-capture-group":"error","prefer-destructuring":"error","object-shorthand":"error","require-atomic-updates":"error","require-await":"error",camelcase:["error",{properties:"always",ignoreGlobals:!0}],"no-promise-executor-return":["error",{allowVoid:!0}],"sort-imports":"off","no-console":"off"}},typescript:{overrides:{"ts/no-unused-expressions":["error",{enforceForJSX:!0}],"ts/no-unused-vars":["error",{args:"after-used",caughtErrors:"all",destructuredArrayIgnorePattern:"^_",ignoreRestSiblings:!0}],"ts/array-type":["error",{default:"array-simple",readonly:"array-simple"}],"ts/consistent-type-assertions":["error",{assertionStyle:"as",objectLiteralTypeAssertions:"allow"}],"ts/consistent-type-definitions":["error","interface"],"ts/max-params":["error",{max:5}]}},react:{overrides:{"react-naming-convention/component-name":["error","PascalCase"],"react-naming-convention/filename-extension":["error",{allow:"as-needed",extensions:[".tsx"]}],"react-hooks-extra/no-redundant-custom-hook":"error","react-hooks-extra/no-unnecessary-use-memo":"error","react-hooks-extra/no-unnecessary-use-callback":"error","react-naming-convention/use-state":"error","react-refresh/only-export-components":"error","react-hooks/exhaustive-deps":["error",{additionalHooks:"^use(Deep|Shallow)"}],"react/no-clone-element":"off","react/no-class-component":"error","react/no-children-prop":"off","react/no-children-to-array":"off","react/no-children-for-each":"off","react/no-children-count":"off"}},vue:!1,jsx:!0,regexp:!0,jsonc:!0,yaml:!0,toml:!0,markdown:{overrides:{"markdown/fenced-code-language":"error","markdown/no-duplicate-headings":"error","markdown/no-empty-links":"error"}},test:!0,formatters:{markdown:"prettier",prettierOptions:{singleQuote:!1,semi:!0,tabWidth:2,useTabs:!1,trailingComma:"all",endOfLine:"lf",printWidth:160,proseWrap:"never",arrowParens:"avoid",htmlWhitespaceSensitivity:"strict",bracketSameLine:!0,bracketSpacing:!0,quoteProps:"as-needed",jsxSingleQuote:!1,singleAttributePerLine:!1}}},{rules:{"unicorn/filename-case":["error",{case:"kebabCase",ignore:["README.md"]}],"unicorn/prefer-date-now":"error","unicorn/prefer-string-trim-start-end":"error","unicorn/prefer-string-raw":"error","unicorn/prefer-object-from-entries":"error","unicorn/prefer-default-parameters":"error","unicorn/prefer-array-find":"error","unicorn/prefer-array-flat":"error","unicorn/prefer-array-flat-map":"error","unicorn/prefer-array-index-of":"error","unicorn/prefer-array-some":"error","unicorn/prefer-logical-operator-over-ternary":"error","unicorn/no-array-push-push":"error","unicorn/no-empty-file":"error","unicorn/no-array-for-each":"error","unicorn/no-for-loop":"error","unicorn/no-unnecessary-await":"error","unicorn/no-unnecessary-polyfills":"error","unicorn/no-useless-undefined":"error","unicorn/no-useless-switch-case":"error","unicorn/no-useless-spread":"error","unicorn/no-console-spaces":"error","unicorn/no-unused-properties":"error","unicorn/no-useless-promise-resolve-reject":"error","import/order":"off","import/first":"error","import/export":"error","import/no-named-as-default":"off","import/no-named-default":"off","perfectionist/sort-imports":["error",{type:"natural"}],"perfectionist/sort-exports":["error",{type:"natural"}],"perfectionist/sort-named-imports":["error",{type:"natural",groupKind:"values-first"}],"perfectionist/sort-named-exports":["error",{type:"natural",groupKind:"values-first"}],"eslint-comments/no-unlimited-disable":"off"}},{ignores:["**/*.md","**/*.md/*.{ts,tsx}","**/src/pages/__root.{ts,tsx}"],rules:{"react-naming-convention/filename":["error",{rule:"kebab-case"}]}},...o.configs["flat/recommended"],{rules:{"tailwindcss/migration-from-tailwind-2":"off","tailwindcss/no-arbitrary-value":"off","tailwindcss/classnames-order":"error","tailwindcss/enforces-negative-arbitrary-values":"error","tailwindcss/enforces-shorthand":"error","tailwindcss/no-custom-classname":["error",{whitelist:["vef-.*"]}],"tailwindcss/no-contradicting-classname":"error","tailwindcss/no-unnecessary-arbitrary-value":"error"}},...e.configs["flat/recommended"])}export{defineEslintConfig};
432
3
  /*! VefFramework is a blazingly high-level, modern, flexible, easy-to-use UI framework made by Venus. Follow me on Github: https://github.com/ilxqx! @ilxqx */
package/es/index.js CHANGED
@@ -1,7 +1,3 @@
1
- /*! VefFramework version: 1.0.64, build time: 2025-01-10T01:26:01.941Z, made by Venus. */
2
- export { defineCommitlintConfig } from './commitlint-config.js';
3
- export { defineConfig } from './config.js';
4
- export { defineEslintConfig } from './eslint-config.js';
5
- export { defineStylelintConfig } from './stylelint-config.js';
6
- export { defineTailwindConfig } from './tailwind-config.js';
1
+ /*! VefFramework version: 1.0.66, build time: 2025-01-10T02:50:17.453Z, made by Venus. */
2
+ export{defineCommitlintConfig}from"./commitlint-config.js";export{defineConfig}from"./config.js";export{defineEslintConfig}from"./eslint-config.js";export{defineStylelintConfig}from"./stylelint-config.js";export{defineTailwindConfig}from"./tailwind-config.js";
7
3
  /*! VefFramework is a blazingly high-level, modern, flexible, easy-to-use UI framework made by Venus. Follow me on Github: https://github.com/ilxqx! @ilxqx */
package/es/modules.d.js CHANGED
@@ -1,3 +1,2 @@
1
- /*! VefFramework version: 1.0.64, build time: 2025-01-10T01:26:01.941Z, made by Venus. */
2
-
1
+ /*! VefFramework version: 1.0.66, build time: 2025-01-10T02:50:17.453Z, made by Venus. */
3
2
  /*! VefFramework is a blazingly high-level, modern, flexible, easy-to-use UI framework made by Venus. Follow me on Github: https://github.com/ilxqx! @ilxqx */
@@ -1,35 +1,3 @@
1
- /*! VefFramework version: 1.0.64, build time: 2025-01-10T01:26:01.941Z, made by Venus. */
2
- import { snake } from 'radashi';
3
- import config from 'unplugin-config/vite';
4
- import { DEFAULT_OUTPUT_DIR, ENV_APP_PREFIX, DEFAULT_APP_NAME } from './constants.js';
5
-
6
- function constantCase(value) {
7
- return snake(value).toUpperCase();
8
- }
9
- function createAppConfigPlugin({
10
- basePublicPath,
11
- outputDir,
12
- appName = DEFAULT_APP_NAME
13
- }) {
14
- return config({
15
- appName: `VEF_${constantCase(appName)}`,
16
- baseDir: basePublicPath,
17
- configFile: {
18
- generate: true,
19
- fileName: "app.config.js",
20
- outputDir: outputDir ?? DEFAULT_OUTPUT_DIR
21
- },
22
- htmlInjection: {
23
- enable: true,
24
- position: "head-prepend",
25
- templates: ["index.html"]
26
- },
27
- envVariables: {
28
- prefix: ENV_APP_PREFIX,
29
- files: ["env/.env", "env/.env.production"]
30
- }
31
- });
32
- }
33
-
34
- export { createAppConfigPlugin };
1
+ /*! VefFramework version: 1.0.66, build time: 2025-01-10T02:50:17.453Z, made by Venus. */
2
+ import{snake as e}from"radashi";import i from"unplugin-config/vite";import{DEFAULT_OUTPUT_DIR as n,ENV_APP_PREFIX as p,DEFAULT_APP_NAME as t}from"./constants.js";function createAppConfigPlugin({basePublicPath:a,outputDir:o,appName:r=t}){return i({appName:`VEF_${f=r,e(f).toUpperCase()}`,baseDir:a,configFile:{generate:!0,fileName:"app.config.js",outputDir:o??n},htmlInjection:{enable:!0,position:"head-prepend",templates:["index.html"]},envVariables:{prefix:p,files:["env/.env","env/.env.production"]}});var f}export{createAppConfigPlugin};
35
3
  /*! VefFramework is a blazingly high-level, modern, flexible, easy-to-use UI framework made by Venus. Follow me on Github: https://github.com/ilxqx! @ilxqx */
@@ -1,110 +1,3 @@
1
- /*! VefFramework version: 1.0.64, build time: 2025-01-10T01:26:01.941Z, made by Venus. */
2
- import autoprefixer from 'autoprefixer';
3
- import { resolve } from 'node:path';
4
- import process from 'node:process';
5
- import tailwindcss from 'tailwindcss';
6
- import { ENV_DIR, ENV_BUILD_PREFIX, ENV_APP_PREFIX, DEFAULT_APP_NAME, SRC_DIR, DEFAULT_OUTPUT_DIR, ASSETS_DIR, DEFAULT_SERVER_PORT } from './constants.js';
7
-
8
- function createConventionalConfigPlugin({
9
- appName,
10
- appVersion,
11
- basePublicPath,
12
- projectDir,
13
- outputDir,
14
- serverPort,
15
- proxies
16
- }) {
17
- return {
18
- name: "vef-framework:conventional-config",
19
- config(_, { command }) {
20
- const isDev = command === "serve";
21
- return {
22
- appType: "spa",
23
- root: projectDir,
24
- base: basePublicPath,
25
- publicDir: "public",
26
- envDir: ENV_DIR,
27
- envPrefix: [ENV_BUILD_PREFIX, ENV_APP_PREFIX],
28
- define: {
29
- __VEF_FRAMEWORK_VERSION__: `"${process.env.VEF_FRAMEWORK_VERSION}"`,
30
- __VEF_APP_VERSION__: `"${appVersion}"`,
31
- __VEF_APP_CONFIG__: isDev ? `
32
- (function () {
33
- const env = import.meta.env;
34
- const config = Object.keys(env).filter(key => key.startsWith(${JSON.stringify(ENV_APP_PREFIX)}))
35
- .reduce((acc, key) => {
36
- acc[key] = env[key];
37
- return acc;
38
- }, {});
39
- return Object.freeze(config);
40
- })()
41
- ` : `window.__PRODUCTION__VEF_${appName ?? DEFAULT_APP_NAME}__CONF__`
42
- },
43
- resolve: {
44
- alias: {
45
- "@": SRC_DIR
46
- }
47
- },
48
- css: {
49
- modules: {
50
- scopeBehaviour: "local",
51
- localsConvention: "camelCase"
52
- },
53
- postcss: {
54
- plugins: [
55
- tailwindcss({
56
- config: resolve(projectDir, "tailwind.config.js")
57
- }),
58
- autoprefixer()
59
- ]
60
- }
61
- },
62
- optimizeDeps: {
63
- include: ["react", "react-dom"]
64
- },
65
- esbuild: {
66
- target: "es2023",
67
- drop: ["console", "debugger"]
68
- },
69
- build: {
70
- outDir: outputDir ?? DEFAULT_OUTPUT_DIR,
71
- target: "modules",
72
- assetsDir: ASSETS_DIR,
73
- assetsInlineLimit: 10240,
74
- reportCompressedSize: false,
75
- chunkSizeWarningLimit: 2048,
76
- minify: "terser",
77
- cssMinify: "lightningcss",
78
- sourcemap: false,
79
- rollupOptions: {
80
- maxParallelFileOps: 200,
81
- input: {
82
- main: "index.html"
83
- },
84
- output: {
85
- banner: `/*! Powered by VEF Framework v${process.env.VEF_FRAMEWORK_VERSION}.${appVersion ? ` App version v${appVersion}.` : ""} Built at ${(/* @__PURE__ */ new Date()).toISOString()} */`,
86
- chunkFileNames: `${ASSETS_DIR}/js/[name]-[hash].js`,
87
- entryFileNames: `${ASSETS_DIR}/js/[name]-[hash].js`,
88
- assetFileNames: `${ASSETS_DIR}/[ext]/[name]-[hash].[ext]`,
89
- manualChunks: {
90
- "react": ["react", "react-dom"],
91
- "vef-shared": ["@vef-framework/shared"],
92
- "vef-components": ["@vef-framework/components"],
93
- "vef-foundations": ["@vef-framework/hooks", "@vef-framework/core", "@vef-framework/starter"]
94
- }
95
- }
96
- }
97
- },
98
- server: {
99
- port: serverPort || DEFAULT_SERVER_PORT,
100
- host: true,
101
- open: true,
102
- proxy: proxies
103
- }
104
- };
105
- }
106
- };
107
- }
108
-
109
- export { createConventionalConfigPlugin };
1
+ /*! VefFramework version: 1.0.66, build time: 2025-01-10T02:50:17.453Z, made by Venus. */
2
+ import e from"autoprefixer";import{resolve as n}from"node:path";import r from"node:process";import o from"tailwindcss";import{ENV_DIR as t,ENV_BUILD_PREFIX as i,ENV_APP_PREFIX as s,DEFAULT_APP_NAME as a,DEFAULT_OUTPUT_DIR as c,ASSETS_DIR as m,DEFAULT_SERVER_PORT as p}from"./constants.js";function createConventionalConfigPlugin({appName:f,appVersion:l,basePublicPath:u,projectDir:_,outputDir:v,serverPort:d,proxies:g}){return{name:"vef-framework:conventional-config",config(h,{command:k}){const F="serve"===k;return{appType:"spa",root:_,base:u,publicDir:"public",envDir:t,envPrefix:[i,s],define:{__VEF_FRAMEWORK_VERSION__:`"${r.env.VEF_FRAMEWORK_VERSION}"`,__VEF_APP_VERSION__:`"${l}"`,__VEF_APP_CONFIG__:F?`\n (function () {\n const env = import.meta.env;\n const config = Object.keys(env).filter(key => key.startsWith(${JSON.stringify(s)}))\n .reduce((acc, key) => {\n acc[key] = env[key];\n return acc;\n }, {});\n return Object.freeze(config);\n })()\n `:`window.__PRODUCTION__VEF_${f??a}__CONF__`},css:{modules:{scopeBehaviour:"local",localsConvention:"camelCase"},postcss:{plugins:[o({config:n(_,"tailwind.config.js")}),e()]}},optimizeDeps:{include:["react","react-dom"]},esbuild:{target:"es2023",drop:["console","debugger"]},build:{outDir:v??c,target:"modules",assetsDir:m,assetsInlineLimit:10240,reportCompressedSize:!1,chunkSizeWarningLimit:2048,minify:"terser",cssMinify:"lightningcss",sourcemap:!1,rollupOptions:{maxParallelFileOps:200,input:{main:"index.html"},output:{banner:`/*! Powered by VEF Framework v${r.env.VEF_FRAMEWORK_VERSION}.${l?` App version v${l}.`:""} Built at ${(new Date).toISOString()} */`,chunkFileNames:`${m}/js/[name]-[hash].js`,entryFileNames:`${m}/js/[name]-[hash].js`,assetFileNames:`${m}/[ext]/[name]-[hash].[ext]`,manualChunks:{react:["react","react-dom"],"vef-shared":["@vef-framework/shared"],"vef-components":["@vef-framework/components"],"vef-foundations":["@vef-framework/hooks","@vef-framework/core","@vef-framework/starter"]}}}},server:{port:d||p,host:!0,open:!0,proxy:g}}}}}export{createConventionalConfigPlugin};
110
3
  /*! VefFramework is a blazingly high-level, modern, flexible, easy-to-use UI framework made by Venus. Follow me on Github: https://github.com/ilxqx! @ilxqx */
@@ -1,21 +1,3 @@
1
- /*! VefFramework version: 1.0.64, build time: 2025-01-10T01:26:01.941Z, made by Venus. */
2
- import eslint from 'vite-plugin-eslint2';
3
-
4
- function createEslintPlugin() {
5
- return eslint({
6
- fix: true,
7
- test: true,
8
- dev: true,
9
- build: true,
10
- cache: true,
11
- cacheLocation: "node_modules/.cache/.eslintcache",
12
- include: ["*.{js,ts,json,jsonc,yaml,toml,md}", "src/**/*.{ts,tsx,json,jsonc,yaml,toml,md}"],
13
- exclude: ["node_modules", "virtual:", "vef:"],
14
- emitError: true,
15
- emitWarning: true,
16
- emitWarningAsError: true
17
- });
18
- }
19
-
20
- export { createEslintPlugin };
1
+ /*! VefFramework version: 1.0.66, build time: 2025-01-10T02:50:17.453Z, made by Venus. */
2
+ import e from"vite-plugin-eslint2";function createEslintPlugin(){return e({fix:!0,test:!0,dev:!0,build:!0,cache:!0,cacheLocation:"node_modules/.cache/.eslintcache",include:["*.{js,ts,json,jsonc,yaml,toml,md}","src/**/*.{ts,tsx,json,jsonc,yaml,toml,md}"],exclude:["node_modules","virtual:","vef:"],emitError:!0,emitWarning:!0,emitWarningAsError:!0})}export{createEslintPlugin};
21
3
  /*! VefFramework is a blazingly high-level, modern, flexible, easy-to-use UI framework made by Venus. Follow me on Github: https://github.com/ilxqx! @ilxqx */