@chanom/dev-config 0.0.1

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,43 @@
1
+ import { defineConfig } from 'oxfmt';
2
+
3
+ export default defineConfig({
4
+ useTabs: false,
5
+ tabWidth: 2,
6
+ printWidth: 100,
7
+ singleQuote: true,
8
+ jsxSingleQuote: false,
9
+ quoteProps: 'as-needed',
10
+ trailingComma: 'all',
11
+ semi: true,
12
+ arrowParens: 'always',
13
+ bracketSameLine: false,
14
+ bracketSpacing: true,
15
+ ignorePatterns: [
16
+ '.agents/skills/**/*.md',
17
+ '.claude/skills/**/*.md',
18
+ '**/dist/**',
19
+ '**/node_modules/**',
20
+ '**/build/**',
21
+ '**/.turbo/**',
22
+ '**/storybook-static/**',
23
+ ],
24
+ overrides: [
25
+ {
26
+ files: ['**/*.yaml'],
27
+ options: {
28
+ singleQuote: true,
29
+ },
30
+ },
31
+ ],
32
+ sortImports: {
33
+ groups: [
34
+ 'type-import',
35
+ ['value-builtin', 'value-external'],
36
+ 'type-internal',
37
+ 'value-internal',
38
+ ['type-parent', 'type-sibling', 'type-index'],
39
+ ['value-parent', 'value-sibling', 'value-index'],
40
+ 'unknown',
41
+ ],
42
+ },
43
+ });
package/oxfmt/index.ts ADDED
@@ -0,0 +1,3 @@
1
+ import baseConfig from './base-config.ts';
2
+
3
+ export default baseConfig;
@@ -0,0 +1,29 @@
1
+ import { defineConfig } from 'oxlint';
2
+
3
+ export default defineConfig({
4
+ plugins: ['typescript'],
5
+ categories: {
6
+ correctness: 'error',
7
+ },
8
+ rules: {
9
+ 'no-explicit-any': 'error',
10
+ 'no-unused-expressions': 'off',
11
+ 'no-this-alias': 'off',
12
+ 'no-console': 'error',
13
+ 'no-unused-vars': [
14
+ 'error',
15
+ {
16
+ argsIgnorePattern: '^_',
17
+ varsIgnorePattern: '^_',
18
+ caughtErrorsIgnorePattern: '^_',
19
+ },
20
+ ],
21
+ /**
22
+ * TypeScript Rules
23
+ */
24
+ 'typescript/no-deprecated': 'warn',
25
+ 'typescript/consistent-type-definitions': 'error',
26
+ 'typescript/consistent-type-imports': 'error',
27
+ },
28
+ ignorePatterns: ['**/node_modules/**', '**/.turbo/**'],
29
+ });
@@ -0,0 +1,36 @@
1
+ import { defineConfig } from 'oxlint';
2
+
3
+ import baseConfig from './base-config.ts';
4
+
5
+ export default defineConfig({
6
+ extends: [baseConfig],
7
+ plugins: ['react', 'jsx-a11y'],
8
+ categories: {
9
+ correctness: 'error',
10
+ },
11
+ rules: {
12
+ 'no-restricted-imports': [
13
+ 'error',
14
+ {
15
+ paths: [
16
+ {
17
+ name: 'react',
18
+ importNames: ['default'],
19
+ message: 'Do not import React as default. Use named imports instead.',
20
+ },
21
+ {
22
+ name: 'zod',
23
+ importNames: ['default'],
24
+ message: 'Do not import Zod as default. Use named imports instead.',
25
+ },
26
+ ],
27
+ },
28
+ ],
29
+ /**
30
+ * React Rules
31
+ */
32
+ 'react-hooks/exhaustive-deps': 'warn',
33
+ 'react/rules-of-hooks': 'error',
34
+ },
35
+ ignorePatterns: ['**/env.d.ts', '**/storybook-static/**', '**/dist/**', '**/build/**'],
36
+ });
package/package.json ADDED
@@ -0,0 +1,26 @@
1
+ {
2
+ "name": "@chanom/dev-config",
3
+ "version": "0.0.1",
4
+ "description": "Shared oxlint and oxfmt config",
5
+ "files": [
6
+ "oxfmt",
7
+ "oxlint"
8
+ ],
9
+ "type": "module",
10
+ "exports": {
11
+ "./oxfmt/config": "./oxfmt/index.ts",
12
+ "./oxfmt/base": "./oxfmt/base-config.ts",
13
+ "./oxlint/config": "./oxlint/index.ts",
14
+ "./oxlint/base": "./oxlint/base-config.ts"
15
+ },
16
+ "publishConfig": {
17
+ "access": "public"
18
+ },
19
+ "devDependencies": {
20
+ "@tsconfig/node-ts": "23.6.4"
21
+ },
22
+ "peerDependencies": {
23
+ "oxfmt": "0.56.0",
24
+ "oxlint": "1.71.0"
25
+ }
26
+ }