@papillonarts/setup 0.15.0 → 0.16.0

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.
@@ -0,0 +1,3 @@
1
+ declare const _default: import("@eslint/config-helpers").Config[];
2
+ export default _default;
3
+ //# sourceMappingURL=index.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../src/eslint/index.mjs"],"names":[],"mappings":""}
@@ -0,0 +1,176 @@
1
+ import { defineConfig, globalIgnores } from 'eslint/config'
2
+ import { fixupConfigRules, fixupPluginRules } from '@eslint/compat'
3
+ import react from 'eslint-plugin-react'
4
+ import reactHooks from 'eslint-plugin-react-hooks'
5
+ import jsxA11Y from 'eslint-plugin-jsx-a11y'
6
+ import jest from 'eslint-plugin-jest'
7
+ import prettier from 'eslint-plugin-prettier'
8
+ import globals from 'globals'
9
+ import tsParser from '@typescript-eslint/parser'
10
+ import path from 'node:path'
11
+ import { fileURLToPath } from 'node:url'
12
+ import js from '@eslint/js'
13
+ import { FlatCompat } from '@eslint/eslintrc'
14
+
15
+ const __filename = fileURLToPath(import.meta.url)
16
+ const __dirname = path.dirname(__filename)
17
+ const compat = new FlatCompat({
18
+ baseDirectory: __dirname,
19
+ recommendedConfig: js.configs.recommended,
20
+ allConfig: js.configs.all,
21
+ })
22
+
23
+ export default defineConfig([
24
+ globalIgnores([
25
+ '**/.DS_Store',
26
+ '**/app.sublime-project',
27
+ '**/app.sublime-workspace',
28
+ '**/.storybook-static-develop',
29
+ '**/.storybook-static-release',
30
+ '**/.coverage',
31
+ '**/.husky',
32
+ '**/node_modules',
33
+ '**/.env',
34
+ '**/.npmrc',
35
+ '**/codecov',
36
+ '**/lerna-debug.log',
37
+ '**/npm-debug.log',
38
+ '**/package-lock.json',
39
+ 'packages/components/package-lock.json',
40
+ 'packages/components/build',
41
+ 'packages/components/node_modules',
42
+ 'packages/CSS/package-lock.json',
43
+ 'packages/CSS/build',
44
+ 'packages/CSS/node_modules',
45
+ 'packages/CSS/src/primer',
46
+ 'packages/library/package-lock.json',
47
+ 'packages/library/build',
48
+ 'packages/library/node_modules',
49
+ 'packages/setup/package-lock.json',
50
+ 'packages/setup/build',
51
+ 'packages/setup/node_modules',
52
+ ]),
53
+ {
54
+ extends: fixupConfigRules(
55
+ compat.extends(
56
+ 'eslint:recommended',
57
+ 'plugin:import/errors',
58
+ 'plugin:import/warnings',
59
+ 'plugin:react/recommended',
60
+ 'plugin:jsx-a11y/recommended',
61
+ 'plugin:jest/recommended',
62
+ 'prettier',
63
+ 'plugin:@typescript-eslint/stylistic-type-checked',
64
+ ),
65
+ ),
66
+
67
+ files: ['**/*.ts', '**/*.tsx'],
68
+
69
+ plugins: {
70
+ react: fixupPluginRules(react),
71
+ 'react-hooks': fixupPluginRules(reactHooks),
72
+ 'jsx-a11y': fixupPluginRules(jsxA11Y),
73
+ jest: fixupPluginRules(jest),
74
+ prettier,
75
+ },
76
+
77
+ languageOptions: {
78
+ globals: {
79
+ ...globals.amd,
80
+ ...globals.browser,
81
+ ...globals.commonjs,
82
+ ...globals.jasmine,
83
+ ...globals.jest,
84
+ ...globals.mocha,
85
+ ...globals.node,
86
+ document: false,
87
+ expect: false,
88
+ jest: false,
89
+ jsdom: true,
90
+ renderMount: false,
91
+ renderShallow: false,
92
+ },
93
+
94
+ parser: tsParser,
95
+ ecmaVersion: 16,
96
+ sourceType: 'commonjs',
97
+
98
+ parserOptions: {
99
+ ecmaFeatures: {
100
+ jsx: true,
101
+ },
102
+
103
+ projectService: {
104
+ allowDefaultProject: ['*.js', '*.jsx', '*.ts', '*.tsx'],
105
+ },
106
+ },
107
+ },
108
+
109
+ settings: {
110
+ 'import/resolver': {
111
+ alias: {
112
+ map: [['@papillonarts/components', '@papillonarts/components/build']],
113
+ extensions: ['.js', '.jsx', '.ts', '.tsx'],
114
+ },
115
+
116
+ node: {
117
+ extensions: ['.js', '.jsx', '.ts', '.tsx'],
118
+ },
119
+ },
120
+
121
+ react: {
122
+ version: '19.2.0',
123
+ },
124
+ },
125
+
126
+ rules: {
127
+ 'import/named': 2,
128
+
129
+ 'import/no-extraneous-dependencies': [
130
+ 0,
131
+ {
132
+ devDependencies: ['**/*.test.js', '**/*.story.js', '**/*.test.ts', '**/*.story.tsx'],
133
+ },
134
+ ],
135
+
136
+ 'import/prefer-default-export': 'off',
137
+ 'import/no-relative-packages': 'off',
138
+ 'jsx-a11y/accessible-emoji': 0,
139
+ 'prettier/prettier': 'error',
140
+ 'react-hooks/exhaustive-deps': 'warn',
141
+ 'react-hooks/rules-of-hooks': 'error',
142
+ 'react/jsx-boolean-value': 0,
143
+
144
+ 'react/jsx-filename-extension': [
145
+ 2,
146
+ {
147
+ extensions: ['.js', '.jsx', '.ts', '.tsx'],
148
+ },
149
+ ],
150
+
151
+ 'react/jsx-fragments': 0,
152
+ 'react/jsx-props-no-spreading': 0,
153
+ 'react/jsx-uses-react': 'off',
154
+ 'react/react-in-jsx-scope': 'off',
155
+ semi: ['error', 'never'],
156
+
157
+ 'import/extensions': [
158
+ 'error',
159
+ 'ignorePackages',
160
+ {
161
+ js: 'never',
162
+ jsx: 'never',
163
+ ts: 'never',
164
+ tsx: 'never',
165
+ },
166
+ ],
167
+
168
+ '@typescript-eslint/no-empty-function': 0,
169
+ '@typescript-eslint/strict-boolean-expressions': 0,
170
+ '@typescript-eslint/prefer-nullish-coalescing': 0,
171
+ 'object-curly-spacing': 0,
172
+ 'comma-dangle': 0,
173
+ 'no-unused-vars': 0,
174
+ },
175
+ },
176
+ ])
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@papillonarts/setup",
3
- "version": "0.15.0",
3
+ "version": "0.16.0",
4
4
  "description": "Papillon Arts Setup",
5
5
  "homepage": "https://github.com/papillonarts/papillonarts/tree/master/packages/setup",
6
6
  "repository": {
@@ -31,5 +31,5 @@
31
31
  "build-acceptance": "npm run build",
32
32
  "build-release": "npm run build"
33
33
  },
34
- "gitHead": "291d2e4d18ff4a9d17382920abc5cd3824911206"
34
+ "gitHead": "d21138ad2e8be241ce8b4eb519bc621c034618dd"
35
35
  }
package/eslint/index.d.ts DELETED
@@ -1,80 +0,0 @@
1
- export declare namespace env {
2
- let amd: boolean;
3
- let browser: boolean;
4
- let commonjs: boolean;
5
- let es2020: boolean;
6
- let jasmine: boolean;
7
- let jest: boolean;
8
- let mocha: boolean;
9
- let node: boolean;
10
- }
11
- declare let _extends: string[];
12
- export { _extends as extends };
13
- export declare namespace globals {
14
- export let document: boolean;
15
- export let expect: boolean;
16
- let jest_1: boolean;
17
- export { jest_1 as jest };
18
- export let jsdom: boolean;
19
- export let renderMount: boolean;
20
- export let renderShallow: boolean;
21
- }
22
- export declare let parser: string;
23
- export declare namespace parserOptions {
24
- namespace ecmaFeatures {
25
- let jsx: boolean;
26
- }
27
- let ecmaVersion: number;
28
- namespace projectService {
29
- let allowDefaultProject: string[];
30
- }
31
- }
32
- export declare let plugins: string[];
33
- export declare let rules: {
34
- 'import/named': number;
35
- 'import/no-extraneous-dependencies': (number | {
36
- devDependencies: string[];
37
- })[];
38
- 'import/prefer-default-export': string;
39
- 'import/no-relative-packages': string;
40
- 'jsx-a11y/accessible-emoji': number;
41
- 'prettier/prettier': string;
42
- 'react-hooks/exhaustive-deps': string;
43
- 'react-hooks/rules-of-hooks': string;
44
- 'react/jsx-boolean-value': number;
45
- 'react/jsx-filename-extension': (number | {
46
- extensions: string[];
47
- })[];
48
- 'react/jsx-fragments': number;
49
- 'react/jsx-props-no-spreading': number;
50
- 'react/jsx-uses-react': string;
51
- 'react/react-in-jsx-scope': string;
52
- semi: string[];
53
- 'import/extensions': (string | {
54
- js: string;
55
- jsx: string;
56
- ts: string;
57
- tsx: string;
58
- })[];
59
- '@typescript-eslint/no-empty-function': number;
60
- '@typescript-eslint/strict-boolean-expressions': number;
61
- '@typescript-eslint/prefer-nullish-coalescing': number;
62
- 'object-curly-spacing': number;
63
- 'comma-dangle': number;
64
- 'no-unused-vars': number;
65
- };
66
- export declare let settings: {
67
- 'import/resolver': {
68
- alias: {
69
- map: string[][];
70
- extensions: string[];
71
- };
72
- node: {
73
- extensions: string[];
74
- };
75
- };
76
- react: {
77
- version: string;
78
- };
79
- };
80
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/eslint/index.js"],"names":[],"mappings":""}
package/eslint/index.js DELETED
@@ -1,84 +0,0 @@
1
- "use strict";
2
-
3
- // https://typescript-eslint.io/users/configs/
4
-
5
- module.exports = {
6
- env: {
7
- amd: true,
8
- browser: true,
9
- commonjs: true,
10
- es2020: true,
11
- jasmine: true,
12
- jest: true,
13
- mocha: true,
14
- node: true
15
- },
16
- "extends": ['eslint:recommended', 'plugin:import/errors', 'plugin:import/warnings', 'plugin:react/recommended', 'plugin:jsx-a11y/recommended', 'plugin:jest/recommended', 'prettier', 'plugin:@typescript-eslint/stylistic-type-checked'],
17
- globals: {
18
- document: false,
19
- expect: false,
20
- jest: false,
21
- jsdom: true,
22
- renderMount: false,
23
- renderShallow: false
24
- },
25
- parser: '@typescript-eslint/parser',
26
- // https://typescript-eslint.io/packages/parser/#configuration
27
- parserOptions: {
28
- ecmaFeatures: {
29
- jsx: true
30
- },
31
- ecmaVersion: 16,
32
- projectService: {
33
- allowDefaultProject: ['*.js', '*.jsx', '*.ts', '*.tsx']
34
- }
35
- },
36
- plugins: ['react', 'react-hooks', 'jsx-a11y', 'jest', 'prettier'],
37
- rules: {
38
- 'import/named': 2,
39
- 'import/no-extraneous-dependencies': [0, {
40
- devDependencies: ['**/*.test.js', '**/*.story.js', '**/*.test.ts', '**/*.story.tsx']
41
- }],
42
- 'import/prefer-default-export': 'off',
43
- 'import/no-relative-packages': 'off',
44
- 'jsx-a11y/accessible-emoji': 0,
45
- 'prettier/prettier': 'error',
46
- 'react-hooks/exhaustive-deps': 'warn',
47
- 'react-hooks/rules-of-hooks': 'error',
48
- 'react/jsx-boolean-value': 0,
49
- 'react/jsx-filename-extension': [2, {
50
- extensions: ['.js', '.jsx', '.ts', '.tsx']
51
- }],
52
- 'react/jsx-fragments': 0,
53
- 'react/jsx-props-no-spreading': 0,
54
- 'react/jsx-uses-react': 'off',
55
- 'react/react-in-jsx-scope': 'off',
56
- semi: ['error', 'never'],
57
- 'import/extensions': ['error', 'ignorePackages', {
58
- js: 'never',
59
- jsx: 'never',
60
- ts: 'never',
61
- tsx: 'never'
62
- }],
63
- '@typescript-eslint/no-empty-function': 0,
64
- '@typescript-eslint/strict-boolean-expressions': 0,
65
- '@typescript-eslint/prefer-nullish-coalescing': 0,
66
- 'object-curly-spacing': 0,
67
- 'comma-dangle': 0,
68
- 'no-unused-vars': 0
69
- },
70
- settings: {
71
- 'import/resolver': {
72
- alias: {
73
- map: [['@papillonarts/components', '@papillonarts/components/build']],
74
- extensions: ['.js', '.jsx', '.ts', '.tsx']
75
- },
76
- node: {
77
- extensions: ['.js', '.jsx', '.ts', '.tsx']
78
- }
79
- },
80
- react: {
81
- version: '19.2.0'
82
- }
83
- }
84
- };