@tsofist/web-buddy 1.22.0 → 2.0.0-next.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.
Files changed (62) hide show
  1. package/.editorconfig +16 -5
  2. package/LICENSE +167 -21
  3. package/README.md +4 -57
  4. package/lib/eslint/config.d.ts +1200 -0
  5. package/lib/eslint/config.fws-mercurio.d.ts +2 -0
  6. package/lib/eslint/config.fws-mercurio.js +15 -0
  7. package/lib/eslint/config.js +38 -0
  8. package/lib/eslint/config.json.d.ts +2 -0
  9. package/lib/eslint/config.json.js +20 -0
  10. package/lib/eslint/config.json.rules.d.ts +3 -0
  11. package/lib/eslint/config.json.rules.js +9 -0
  12. package/lib/eslint/config.shared.rules.d.ts +3 -0
  13. package/lib/eslint/config.shared.rules.js +58 -0
  14. package/lib/eslint/config.typescript.d.ts +2 -0
  15. package/lib/eslint/config.typescript.js +33 -0
  16. package/lib/eslint/config.typescript.rules.d.ts +2 -0
  17. package/lib/eslint/config.typescript.rules.js +147 -0
  18. package/lib/eslint/config.vue.d.ts +5 -0
  19. package/lib/eslint/config.vue.js +43 -0
  20. package/lib/eslint/config.vue.rules.d.ts +5 -0
  21. package/lib/eslint/config.vue.rules.js +61 -0
  22. package/lib/eslint/config.yaml.d.ts +2 -0
  23. package/lib/eslint/config.yaml.js +13 -0
  24. package/lib/eslint/config.yaml.rules.d.ts +2 -0
  25. package/lib/eslint/config.yaml.rules.js +6 -0
  26. package/lib/eslint/ignores.d.ts +1 -0
  27. package/lib/eslint/ignores.js +38 -0
  28. package/lib/prettier/config.d.ts +39 -0
  29. package/{.prettierrc.js → lib/prettier/config.js} +4 -3
  30. package/lib/semantic-release/config.github.d.ts +16 -0
  31. package/lib/semantic-release/config.github.js +3 -0
  32. package/lib/semantic-release/config.gitlab.d.ts +16 -0
  33. package/lib/semantic-release/config.gitlab.js +3 -0
  34. package/lib/semantic-release/configuration-bootstrap.d.ts +84 -0
  35. package/lib/semantic-release/configuration-bootstrap.js +53 -0
  36. package/lib/stricter-mode.d.ts +1 -0
  37. package/lib/stricter-mode.js +2 -0
  38. package/lib/stylelint/config.d.ts +11 -0
  39. package/lib/stylelint/config.js +21 -0
  40. package/lib/stylelint/rules.d.ts +2 -0
  41. package/lib/stylelint/rules.js +19 -0
  42. package/lib/tsconfig/config.base.json +18 -0
  43. package/lib/tsconfig/config.isomorphic.json +6 -0
  44. package/lib/tsconfig/config.web.json +11 -0
  45. package/lib/types.d.ts +14 -0
  46. package/lib/types.js +1 -0
  47. package/package.json +42 -42
  48. package/.eslintrc.yaml +0 -66
  49. package/.releaserc-github.json +0 -23
  50. package/.releaserc-gitlab.json +0 -23
  51. package/.stylelintrc.yaml +0 -49
  52. package/eslint/shared.yaml +0 -66
  53. package/eslint/stricter.extends.yaml +0 -10
  54. package/eslint/typescript/common.yaml +0 -20
  55. package/eslint/typescript/rules.yaml +0 -159
  56. package/eslint/typescript/stricter.rules.yaml +0 -4
  57. package/eslint/vue/common.yaml +0 -36
  58. package/eslint/vue/rules.yaml +0 -63
  59. package/eslint/yaml/common.yaml +0 -22
  60. package/tsconfig/base.json +0 -18
  61. package/tsconfig/browser.json +0 -10
  62. package/tsconfig/server.json +0 -6
@@ -0,0 +1,2 @@
1
+ import type { ESLintConfigChain } from '../types.js';
2
+ export declare const WebBuddyESLintFrameworkSpecificConfigForMercurio: ESLintConfigChain;
@@ -0,0 +1,15 @@
1
+ export const WebBuddyESLintFrameworkSpecificConfigForMercurio = [
2
+ {
3
+ files: ['**/*.controller.ts', '**/*.service.ts'],
4
+ rules: {
5
+ '@typescript-eslint/require-await': 'off',
6
+ },
7
+ },
8
+ {
9
+ files: ['**/service-api.types.ts'],
10
+ rules: {
11
+ '@typescript-eslint/consistent-type-definitions': 'off',
12
+ '@typescript-eslint/method-signature-style': ['error', 'method'],
13
+ },
14
+ },
15
+ ];
@@ -0,0 +1,38 @@
1
+ import epJS from '@eslint/js';
2
+ import epStylistic from '@stylistic/eslint-plugin';
3
+ import { defineConfig } from 'eslint/config';
4
+ import { importX as epImportX } from 'eslint-plugin-import-x';
5
+ import epPrettier from 'eslint-plugin-prettier';
6
+ import { WebBuddyESLintFrameworkSpecificConfigForMercurio } from './config.fws-mercurio.js';
7
+ import { WebBuddyESLintJSON } from './config.json.js';
8
+ import { WebBuddyESLintRulesShared } from './config.shared.rules.js';
9
+ import { WebBuddyESLintTypeScript } from './config.typescript.js';
10
+ import { WebBuddyESLintVue } from './config.vue.js';
11
+ import { WebBuddyESLintYAML } from './config.yaml.js';
12
+ import { WebBuddyESLintIgnores } from './ignores.js';
13
+ export default createWebBuddyESLintConfig();
14
+ export function createWebBuddyESLintConfig() {
15
+ return defineConfig(...createWebBuddyESLintConfigGeneralChain(), ...WebBuddyESLintJSON, WebBuddyESLintTypeScript, WebBuddyESLintVue, ...WebBuddyESLintFrameworkSpecificConfigForMercurio, WebBuddyESLintYAML);
16
+ }
17
+ function createWebBuddyESLintConfigGeneralChain() {
18
+ return [
19
+ { ignores: WebBuddyESLintIgnores },
20
+ {
21
+ plugins: {
22
+ '@stylistic': epStylistic,
23
+ 'prettier': epPrettier,
24
+ 'import-x': epImportX,
25
+ },
26
+ settings: {
27
+ 'import-x/resolver': { typescript: true },
28
+ },
29
+ },
30
+ epJS.configs.recommended,
31
+ {
32
+ rules: {
33
+ 'prettier/prettier': 'error',
34
+ ...WebBuddyESLintRulesShared,
35
+ },
36
+ },
37
+ ];
38
+ }
@@ -0,0 +1,2 @@
1
+ import type { ESLintConfigChain } from '../types.js';
2
+ export declare const WebBuddyESLintJSON: ESLintConfigChain;
@@ -0,0 +1,20 @@
1
+ import epJSONC from 'eslint-plugin-jsonc';
2
+ import { WebBuddyESLintJSONCRules, WebBuddyESLintJSONRules } from './config.json.rules.js';
3
+ import { WebBuddyESLintRulesShared } from './config.shared.rules.js';
4
+ export const WebBuddyESLintJSON = [
5
+ {
6
+ files: ['**/*.{json,jsonc,json5}'],
7
+ extends: [epJSONC.configs['flat/all'], epJSONC.configs['flat/prettier']],
8
+ rules: {
9
+ ...WebBuddyESLintRulesShared,
10
+ ...WebBuddyESLintJSONRules,
11
+ },
12
+ },
13
+ {
14
+ files: ['**/*.{jsonc,json5}', 'tsconfig.json', 'tsconfig.*.json'],
15
+ rules: {
16
+ ...WebBuddyESLintRulesShared,
17
+ ...WebBuddyESLintJSONCRules,
18
+ },
19
+ },
20
+ ];
@@ -0,0 +1,3 @@
1
+ import type { ESLintRuleSet } from '../types.js';
2
+ export declare const WebBuddyESLintJSONRules: ESLintRuleSet;
3
+ export declare const WebBuddyESLintJSONCRules: ESLintRuleSet;
@@ -0,0 +1,9 @@
1
+ export const WebBuddyESLintJSONRules = {
2
+ 'jsonc/sort-keys': 'off',
3
+ 'jsonc/key-name-casing': 'off',
4
+ };
5
+ export const WebBuddyESLintJSONCRules = {
6
+ ...WebBuddyESLintJSONRules,
7
+ 'jsonc/no-comments': 'off',
8
+ 'jsonc/comma-dangle': ['error', 'never'],
9
+ };
@@ -0,0 +1,3 @@
1
+ import type { ESLintRuleSet } from '../types.js';
2
+ export declare const WebBuddyESLintVueExtraFileExtensions: readonly [".vue"];
3
+ export declare const WebBuddyESLintRulesShared: ESLintRuleSet;
@@ -0,0 +1,58 @@
1
+ export const WebBuddyESLintVueExtraFileExtensions = ['.vue'];
2
+ export const WebBuddyESLintRulesShared = {
3
+ 'object-shorthand': ['error', 'properties'],
4
+ 'spaced-comment': ['error', 'always', { block: { balanced: true } }],
5
+ //
6
+ 'one-var': ['error', 'never'],
7
+ 'no-multi-spaces': 'error',
8
+ 'no-multiple-empty-lines': ['error', { max: 1, maxEOF: 0, maxBOF: 0 }],
9
+ 'object-curly-spacing': ['error', 'always'],
10
+ 'quotes': [
11
+ 'error',
12
+ 'single',
13
+ {
14
+ allowTemplateLiterals: true,
15
+ avoidEscape: true,
16
+ },
17
+ ],
18
+ 'no-restricted-imports': [
19
+ 'error',
20
+ {
21
+ paths: [
22
+ {
23
+ name: 'lodash',
24
+ message: 'NEVER IMPORT lodash. Use ONLY DIRECT lodash-es/<SOME-TOOL>',
25
+ },
26
+ {
27
+ name: 'lodash-es',
28
+ message: 'NEVER IMPORT lodash-es. Use ONLY lodash-es/<SOME-TOOL>',
29
+ },
30
+ ],
31
+ },
32
+ ],
33
+ 'no-new-wrappers': 'error',
34
+ 'quote-props': ['error', 'consistent-as-needed'],
35
+ 'no-return-await': 'error',
36
+ 'key-spacing': 'error',
37
+ 'block-spacing': 'error',
38
+ 'semi-spacing': 'error',
39
+ 'keyword-spacing': 'error',
40
+ 'space-before-blocks': 'error',
41
+ 'brace-style': 'error',
42
+ 'arrow-spacing': 'error',
43
+ //
44
+ 'import-x/no-named-as-default-member': 'off',
45
+ 'import-x/newline-after-import': 'error',
46
+ 'import-x/no-duplicates': 'error',
47
+ 'import-x/order': [
48
+ 'error',
49
+ {
50
+ 'newlines-between': 'never',
51
+ 'alphabetize': {
52
+ order: 'asc',
53
+ caseInsensitive: false,
54
+ },
55
+ 'groups': ['builtin', 'external', 'internal', 'parent', 'sibling', 'index'],
56
+ },
57
+ ],
58
+ };
@@ -0,0 +1,2 @@
1
+ import type { ESLintConfigChainElement } from '../types.js';
2
+ export declare const WebBuddyESLintTypeScript: ESLintConfigChainElement;
@@ -0,0 +1,33 @@
1
+ import epJS from '@eslint/js';
2
+ import epDecoratorPosition from 'eslint-plugin-decorator-position/config/recommended';
3
+ import { importX as epImportX } from 'eslint-plugin-import-x';
4
+ import epTS from 'typescript-eslint';
5
+ import { WebBuddyESLintRulesShared, WebBuddyESLintVueExtraFileExtensions, } from './config.shared.rules.js';
6
+ import { WebBuddyESLintTypeScriptRules } from './config.typescript.rules.js';
7
+ export const WebBuddyESLintTypeScript = {
8
+ files: ['**/*.{ts,mts,tsx}'],
9
+ extends: [
10
+ epJS.configs.recommended,
11
+ //
12
+ epImportX.flatConfigs.recommended,
13
+ epImportX.flatConfigs.typescript,
14
+ //
15
+ ...epTS.configs.strictTypeChecked,
16
+ ...epTS.configs.stylisticTypeChecked,
17
+ //
18
+ epDecoratorPosition,
19
+ ],
20
+ languageOptions: {
21
+ ecmaVersion: 'latest',
22
+ sourceType: 'module',
23
+ parser: epTS.parser,
24
+ parserOptions: {
25
+ projectService: true,
26
+ extraFileExtensions: WebBuddyESLintVueExtraFileExtensions,
27
+ },
28
+ },
29
+ rules: {
30
+ ...WebBuddyESLintRulesShared,
31
+ ...WebBuddyESLintTypeScriptRules,
32
+ },
33
+ };
@@ -0,0 +1,2 @@
1
+ import type { ESLintRuleSet } from '../types.js';
2
+ export declare const WebBuddyESLintTypeScriptRules: ESLintRuleSet;
@@ -0,0 +1,147 @@
1
+ import { WebBuddyStricterMode } from '../stricter-mode.js';
2
+ /*
3
+ TODO!
4
+
5
+ https://github.com/typescript-eslint/typescript-eslint/issues/8700
6
+ https://typescript-eslint.io/rules/ban-types/
7
+ https://typescript-eslint.io/rules/no-empty-object-type/
8
+
9
+ https://typescript-eslint.io/rules/no-unnecessary-type-assertion/
10
+
11
+ https://eslint.vuejs.org/rules/script-indent
12
+
13
+ */
14
+ export const WebBuddyESLintTypeScriptRules = {
15
+ '@typescript-eslint/no-empty-object-type': 'off', // harmful
16
+ '@typescript-eslint/consistent-indexed-object-style': 'off', // harmful
17
+ '@typescript-eslint/no-inferrable-types': 'off', // harmful
18
+ '@typescript-eslint/consistent-type-definitions': ['error', 'type'],
19
+ 'decorator-position/decorator-position': ['error', { properties: 'above', methods: 'above' }],
20
+ '@typescript-eslint/no-unnecessary-type-parameters': 'off', // odd
21
+ '@typescript-eslint/no-unnecessary-condition': 'off', // odd
22
+ '@typescript-eslint/explicit-member-accessibility': ['error', { accessibility: 'no-public' }],
23
+ '@typescript-eslint/no-restricted-types': [
24
+ 'warn',
25
+ {
26
+ types: {
27
+ Record: {
28
+ message: 'Avoid using the Record type as it may pose some risks. Instead, consider using the @tsofist/stem: PRec/Rec type (Your Stem. With LOVE).',
29
+ suggest: ['PRec', 'Rec'],
30
+ },
31
+ },
32
+ },
33
+ ],
34
+ '@typescript-eslint/ban-ts-comment': [
35
+ 'error',
36
+ {
37
+ 'minimumDescriptionLength': 7,
38
+ 'ts-expect-error': 'allow-with-description',
39
+ 'ts-nocheck': 'allow-with-description',
40
+ 'ts-ignore': true,
41
+ 'ts-check': false,
42
+ },
43
+ ],
44
+ '@typescript-eslint/explicit-module-boundary-types': 'off',
45
+ '@typescript-eslint/no-explicit-any': 'off',
46
+ '@typescript-eslint/no-non-null-assertion': 'off',
47
+ '@typescript-eslint/no-this-alias': 'error',
48
+ '@typescript-eslint/return-await': 'off',
49
+ '@typescript-eslint/no-floating-promises': 'error',
50
+ '@typescript-eslint/no-unnecessary-type-assertion': 'error',
51
+ '@typescript-eslint/no-misused-new': 'error',
52
+ '@typescript-eslint/no-misused-promises': 'off',
53
+ '@typescript-eslint/no-array-constructor': 'error',
54
+ '@typescript-eslint/no-useless-constructor': 'error',
55
+ '@typescript-eslint/adjacent-overload-signatures': 'error',
56
+ '@typescript-eslint/consistent-type-assertions': 'error',
57
+ 'semi': 'error',
58
+ '@stylistic/semi': ['error', 'always'],
59
+ '@stylistic/member-delimiter-style': [
60
+ 'error',
61
+ {
62
+ multiline: { delimiter: 'semi', requireLast: true },
63
+ singleline: { delimiter: 'semi', requireLast: false },
64
+ },
65
+ ],
66
+ '@stylistic/space-before-function-paren': [
67
+ 'warn',
68
+ {
69
+ anonymous: 'always',
70
+ named: 'never',
71
+ asyncArrow: 'always',
72
+ },
73
+ ],
74
+ '@typescript-eslint/no-meaningless-void-operator': 'error',
75
+ '@typescript-eslint/no-redundant-type-constituents': 'off',
76
+ '@typescript-eslint/method-signature-style': ['error', 'property'],
77
+ 'lines-between-class-members': 'off',
78
+ '@stylistic/lines-between-class-members': [
79
+ 'error',
80
+ 'always',
81
+ { exceptAfterSingleLine: true, exceptAfterOverload: true },
82
+ ],
83
+ 'indent': 'off',
84
+ '@typescript-eslint/indent': 'off', // by prettier
85
+ 'no-unused-vars': 'off',
86
+ '@typescript-eslint/no-unused-vars': 'off', // by tsc
87
+ 'no-trailing-spaces': 'off',
88
+ '@stylistic/space-in-parens': 'error',
89
+ '@stylistic/function-call-spacing': 'error',
90
+ '@typescript-eslint/unbound-method': ['error', { ignoreStatic: true }],
91
+ '@typescript-eslint/no-invalid-void-type': [
92
+ 'error',
93
+ {
94
+ allowAsThisParameter: true,
95
+ allowInGenericTypeArguments: true,
96
+ },
97
+ ],
98
+ '@typescript-eslint/no-confusing-void-expression': [
99
+ 'warn',
100
+ {
101
+ ignoreArrowShorthand: true,
102
+ ignoreVoidOperator: true,
103
+ },
104
+ ],
105
+ '@typescript-eslint/restrict-plus-operands': [
106
+ 'error',
107
+ {
108
+ allowAny: false,
109
+ allowBoolean: false,
110
+ allowNullish: false,
111
+ allowNumberAndString: false,
112
+ allowRegExp: false,
113
+ },
114
+ ],
115
+ '@typescript-eslint/restrict-template-expressions': [
116
+ 'error',
117
+ {
118
+ allowAny: false,
119
+ allowNullish: false,
120
+ allowRegExp: false,
121
+ allowNumber: true,
122
+ allowBoolean: true,
123
+ allowNever: true,
124
+ },
125
+ ],
126
+ '@typescript-eslint/no-extraneous-class': [
127
+ 'error',
128
+ { allowWithDecorator: true, allowStaticOnly: true },
129
+ ],
130
+ '@typescript-eslint/no-wrapper-object-types': 'error',
131
+ '@typescript-eslint/unified-signatures': 'off', // odd
132
+ '@typescript-eslint/no-unsafe-enum-comparison': 'off', // odd
133
+ '@typescript-eslint/no-duplicate-type-constituents': 'off', // odd
134
+ '@typescript-eslint/no-dynamic-delete': 'off', // fine in general
135
+ '@typescript-eslint/no-unsafe-assignment': 'off', // by tsc
136
+ '@typescript-eslint/no-unsafe-call': 'off', // odd
137
+ '@typescript-eslint/no-unsafe-argument': 'off', // strict
138
+ '@typescript-eslint/no-unsafe-member-access': 'off', // strict
139
+ '@typescript-eslint/no-unsafe-return': 'off', // strict
140
+ };
141
+ if (WebBuddyStricterMode) {
142
+ Object.assign(WebBuddyESLintTypeScriptRules, {
143
+ '@typescript-eslint/no-unsafe-argument': 'error',
144
+ '@typescript-eslint/no-unsafe-return': 'error',
145
+ '@typescript-eslint/no-unsafe-member-access': 'off', // odd
146
+ });
147
+ }
@@ -0,0 +1,5 @@
1
+ import type { ESLintConfigChainElement } from '../types.js';
2
+ /**
3
+ * @see https://github.com/oxc-project/oxc/issues/15761 TODO: oxc migration blocker
4
+ */
5
+ export declare const WebBuddyESLintVue: ESLintConfigChainElement;
@@ -0,0 +1,43 @@
1
+ import epJS from '@eslint/js';
2
+ import epDecoratorPosition from 'eslint-plugin-decorator-position/config/recommended';
3
+ import { importX as epImportX } from 'eslint-plugin-import-x';
4
+ import epVue from 'eslint-plugin-vue';
5
+ import globals from 'globals';
6
+ import epTS from 'typescript-eslint';
7
+ import { WebBuddyESLintRulesShared, WebBuddyESLintVueExtraFileExtensions, } from './config.shared.rules.js';
8
+ import { WebBuddyESLintTypeScriptRules } from './config.typescript.rules.js';
9
+ import { WebBuddyESLintVueRules } from './config.vue.rules.js';
10
+ /**
11
+ * @see https://github.com/oxc-project/oxc/issues/15761 TODO: oxc migration blocker
12
+ */
13
+ export const WebBuddyESLintVue = {
14
+ files: ['**/*.vue'],
15
+ extends: [
16
+ epJS.configs.recommended,
17
+ //
18
+ epImportX.flatConfigs.recommended,
19
+ epImportX.flatConfigs.typescript,
20
+ //
21
+ ...epTS.configs.strictTypeChecked,
22
+ ...epTS.configs.stylisticTypeChecked,
23
+ //
24
+ epDecoratorPosition,
25
+ //
26
+ ...epVue.configs['flat/recommended'],
27
+ ],
28
+ languageOptions: {
29
+ ecmaVersion: 'latest',
30
+ sourceType: 'module',
31
+ globals: globals.browser, // todo others?
32
+ parserOptions: {
33
+ parser: epTS.parser,
34
+ projectService: true,
35
+ extraFileExtensions: WebBuddyESLintVueExtraFileExtensions,
36
+ },
37
+ },
38
+ rules: {
39
+ ...WebBuddyESLintRulesShared,
40
+ ...WebBuddyESLintTypeScriptRules,
41
+ ...WebBuddyESLintVueRules,
42
+ },
43
+ };
@@ -0,0 +1,5 @@
1
+ import type { ESLintRuleSet } from '../types.js';
2
+ /**
3
+ * @see https://github.com/oxc-project/oxc/issues/15761 TODO: oxc migration blocker
4
+ */
5
+ export declare const WebBuddyESLintVueRules: ESLintRuleSet;
@@ -0,0 +1,61 @@
1
+ /**
2
+ * @see https://github.com/oxc-project/oxc/issues/15761 TODO: oxc migration blocker
3
+ */
4
+ export const WebBuddyESLintVueRules = {
5
+ 'prettier/prettier': 'off', // !
6
+ //
7
+ 'vue/multi-word-component-names': 'off',
8
+ 'vue/html-closing-bracket-newline': ['error'],
9
+ 'indent': 'off',
10
+ '@typescript-eslint/indent': 'off',
11
+ 'vue/html-comment-indent': ['error', 0],
12
+ 'vue/html-indent': [
13
+ 'error',
14
+ 4,
15
+ {
16
+ alignAttributesVertically: true,
17
+ baseIndent: 1,
18
+ closeBracket: 0,
19
+ },
20
+ ],
21
+ 'vue/script-indent': [
22
+ 'error',
23
+ 4,
24
+ {
25
+ baseIndent: 1,
26
+ switchCase: 1,
27
+ },
28
+ ],
29
+ 'vue/max-attributes-per-line': [
30
+ 'error',
31
+ {
32
+ singleline: 3,
33
+ multiline: 1,
34
+ },
35
+ ],
36
+ 'vue/object-curly-spacing': ['error', 'always'],
37
+ 'vue/valid-v-for': 'warn',
38
+ 'vue/component-api-style': ['error', ['script-setup', 'composition']],
39
+ 'vue/no-reserved-component-names': 'off',
40
+ 'vue/attributes-order': [
41
+ 'error',
42
+ {
43
+ alphabetical: true,
44
+ order: [
45
+ 'DEFINITION',
46
+ 'LIST_RENDERING',
47
+ 'CONDITIONALS',
48
+ 'RENDER_MODIFIERS',
49
+ 'GLOBAL',
50
+ ['UNIQUE', 'SLOT'],
51
+ 'TWO_WAY_BINDING',
52
+ 'OTHER_DIRECTIVES',
53
+ 'OTHER_ATTR',
54
+ 'EVENTS',
55
+ 'CONTENT',
56
+ ],
57
+ },
58
+ ],
59
+ 'vue/attribute-hyphenation': ['error', 'always'],
60
+ '@typescript-eslint/no-unnecessary-type-arguments': 'off', // odd
61
+ };
@@ -0,0 +1,2 @@
1
+ import type { ESLintConfigChainElement } from '../types.js';
2
+ export declare const WebBuddyESLintYAML: ESLintConfigChainElement;
@@ -0,0 +1,13 @@
1
+ import { configs } from 'eslint-plugin-yml';
2
+ import * as parser from 'yaml-eslint-parser';
3
+ import { WebBuddyESLintRulesShared } from './config.shared.rules.js';
4
+ import { WebBuddyESLintYAMLRules } from './config.yaml.rules.js';
5
+ export const WebBuddyESLintYAML = {
6
+ files: ['**/*.{yaml,yml}'],
7
+ languageOptions: { parser },
8
+ extends: [configs['flat/standard'], configs['flat/prettier']],
9
+ rules: {
10
+ ...WebBuddyESLintRulesShared,
11
+ ...WebBuddyESLintYAMLRules,
12
+ },
13
+ };
@@ -0,0 +1,2 @@
1
+ import type { ESLintRuleSet } from '../types.js';
2
+ export declare const WebBuddyESLintYAMLRules: ESLintRuleSet;
@@ -0,0 +1,6 @@
1
+ export const WebBuddyESLintYAMLRules = {
2
+ 'yml/plain-scalar': ['error', 'always'],
3
+ 'yml/indent': 'off',
4
+ 'yml/quotes': ['error', { avoidEscape: true, prefer: 'single' }],
5
+ 'yml/block-sequence-hyphen-indicator-newline': ['error', 'never', { nestedHyphen: 'never' }],
6
+ };
@@ -0,0 +1 @@
1
+ export declare const WebBuddyESLintIgnores: string[];
@@ -0,0 +1,38 @@
1
+ export const WebBuddyESLintIgnores = [
2
+ //
3
+ 'package*.json',
4
+ //
5
+ '*.scss',
6
+ '*.css',
7
+ '*.pcss',
8
+ '*.postcss',
9
+ '*.html',
10
+ '*.htm',
11
+ '!.*.yml',
12
+ '!.*.yaml',
13
+ '!.*.json',
14
+ //
15
+ '*.tmp.*',
16
+ '*.private.*',
17
+ '*.tmp/',
18
+ '*.private/',
19
+ //
20
+ '.husky/_/',
21
+ './.cache/',
22
+ './.*-cache/',
23
+ './.coverage/',
24
+ //
25
+ './dist/',
26
+ './lib/',
27
+ '**/node_modules/',
28
+ '**/vendor/',
29
+ //
30
+ '.iml',
31
+ '.idea/',
32
+ '.vscode/',
33
+ '.history/',
34
+ //
35
+ './spec/*.schema*.json',
36
+ './spec/*.openapi.json',
37
+ './spec/*.dbml.json',
38
+ ];
@@ -0,0 +1,39 @@
1
+ export declare const WebBuddyPrettierConfig: {
2
+ arrowParens: string;
3
+ printWidth: number;
4
+ quoteProps: string;
5
+ singleQuote: boolean;
6
+ endOfLine: string;
7
+ tabWidth: number;
8
+ trailingComma: string;
9
+ bracketSpacing: boolean;
10
+ vueIndentScriptAndStyle: boolean;
11
+ bracketSameLine: boolean;
12
+ singleAttributePerLine: boolean;
13
+ overrides: ({
14
+ files: string;
15
+ options: {
16
+ singleQuote: boolean;
17
+ tabWidth: number;
18
+ trailingComma?: undefined;
19
+ };
20
+ parser?: undefined;
21
+ } | {
22
+ files: string;
23
+ parser: string;
24
+ options: {
25
+ tabWidth: number;
26
+ singleQuote?: undefined;
27
+ trailingComma?: undefined;
28
+ };
29
+ } | {
30
+ files: string;
31
+ parser: string;
32
+ options: {
33
+ tabWidth: number;
34
+ trailingComma: string;
35
+ singleQuote?: undefined;
36
+ };
37
+ })[];
38
+ };
39
+ export default WebBuddyPrettierConfig;
@@ -1,4 +1,4 @@
1
- module.exports = {
1
+ export const WebBuddyPrettierConfig = {
2
2
  arrowParens: 'always',
3
3
  printWidth: 100,
4
4
  quoteProps: 'consistent',
@@ -10,7 +10,6 @@ module.exports = {
10
10
  vueIndentScriptAndStyle: true,
11
11
  bracketSameLine: true,
12
12
  singleAttributePerLine: false,
13
-
14
13
  overrides: [
15
14
  {
16
15
  files: '*.{html,htm}',
@@ -27,11 +26,13 @@ module.exports = {
27
26
  },
28
27
  },
29
28
  {
30
- files: '*.json',
29
+ files: '*.{json,jsonc,json5}',
31
30
  parser: 'json',
32
31
  options: {
33
32
  tabWidth: 2,
33
+ trailingComma: 'none',
34
34
  },
35
35
  },
36
36
  ],
37
37
  };
38
+ export default WebBuddyPrettierConfig;
@@ -0,0 +1,16 @@
1
+ export declare const WebBuddySemanticReleaseConfigForGitHub: {
2
+ branches: (string | {
3
+ name: string;
4
+ prerelease: true | string;
5
+ channel?: string;
6
+ } | {
7
+ name: string;
8
+ channel: string;
9
+ range?: string;
10
+ })[];
11
+ plugins: (string | (string | {
12
+ assets: string[];
13
+ message: string;
14
+ })[])[];
15
+ };
16
+ export default WebBuddySemanticReleaseConfigForGitHub;
@@ -0,0 +1,3 @@
1
+ import { bootstrapSemanticReleaseConfig } from './configuration-bootstrap.js';
2
+ export const WebBuddySemanticReleaseConfigForGitHub = bootstrapSemanticReleaseConfig('github');
3
+ export default WebBuddySemanticReleaseConfigForGitHub;
@@ -0,0 +1,16 @@
1
+ export declare const WebBuddySemanticReleaseConfigForGitLab: {
2
+ branches: (string | {
3
+ name: string;
4
+ prerelease: true | string;
5
+ channel?: string;
6
+ } | {
7
+ name: string;
8
+ channel: string;
9
+ range?: string;
10
+ })[];
11
+ plugins: (string | (string | {
12
+ assets: string[];
13
+ message: string;
14
+ })[])[];
15
+ };
16
+ export default WebBuddySemanticReleaseConfigForGitLab;
@@ -0,0 +1,3 @@
1
+ import { bootstrapSemanticReleaseConfig } from './configuration-bootstrap.js';
2
+ export const WebBuddySemanticReleaseConfigForGitLab = bootstrapSemanticReleaseConfig('gitlab');
3
+ export default WebBuddySemanticReleaseConfigForGitLab;