@raidou/oxlint-config-base 0.0.1 → 0.0.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.
package/dist/index.d.ts CHANGED
@@ -1,5 +1,6 @@
1
1
  import { type OxlintConfig } from 'oxlint';
2
- declare const config: OxlintConfig;
2
+ import type { FormatConfig } from 'oxfmt';
3
+ export declare const config: OxlintConfig;
4
+ export declare const fmtconfig: FormatConfig;
3
5
  export type { FormatConfig } from 'oxfmt';
4
6
  export type { OxlintConfig } from 'oxlint';
5
- export { config };
package/dist/index.js CHANGED
@@ -2,7 +2,7 @@ import { defineConfig } from 'oxlint';
2
2
  import { eslintRules } from "./rules/eslint.js";
3
3
  import { reactRules } from "./rules/react.js";
4
4
  import { typescriptRules } from "./rules/typescript.js";
5
- const config = defineConfig({
5
+ export const config = defineConfig({
6
6
  plugins: ['eslint', 'unicorn', 'typescript', 'oxc', 'react', 'import'],
7
7
  options: { typeAware: true },
8
8
  categories: {
@@ -14,5 +14,10 @@ const config = defineConfig({
14
14
  ...reactRules,
15
15
  },
16
16
  });
17
- export { config };
17
+ export const fmtconfig = {
18
+ printWidth: 80,
19
+ semi: false,
20
+ singleQuote: true,
21
+ trailingComma: 'all',
22
+ };
18
23
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAqB,YAAY,EAAE,MAAM,QAAQ,CAAA;AACxD,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAC7C,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAEvD,MAAM,MAAM,GAAiB,YAAY,CAAC;IACxC,OAAO,EAAE,CAAC,QAAQ,EAAE,SAAS,EAAE,YAAY,EAAE,KAAK,EAAE,OAAO,EAAE,QAAQ,CAAC;IACtE,OAAO,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE;IAC5B,UAAU,EAAE;QACV,WAAW,EAAE,OAAO;KACrB;IACD,KAAK,EAAE;QACL,GAAG,eAAe;QAClB,GAAG,WAAW;QACd,GAAG,UAAU;KACd;CACF,CAAC,CAAA;AAIF,OAAO,EAAE,MAAM,EAAE,CAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAqB,YAAY,EAAE,MAAM,QAAQ,CAAA;AAExD,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAC7C,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAEvD,MAAM,CAAC,MAAM,MAAM,GAAiB,YAAY,CAAC;IAC/C,OAAO,EAAE,CAAC,QAAQ,EAAE,SAAS,EAAE,YAAY,EAAE,KAAK,EAAE,OAAO,EAAE,QAAQ,CAAC;IACtE,OAAO,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE;IAC5B,UAAU,EAAE;QACV,WAAW,EAAE,OAAO;KACrB;IACD,KAAK,EAAE;QACL,GAAG,eAAe;QAClB,GAAG,WAAW;QACd,GAAG,UAAU;KACd;CACF,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,SAAS,GAAiB;IACrC,UAAU,EAAE,EAAE;IACd,IAAI,EAAE,KAAK;IACX,WAAW,EAAE,IAAI;IACjB,aAAa,EAAE,KAAK;CACrB,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@raidou/oxlint-config-base",
3
- "version": "0.0.1",
3
+ "version": "0.0.2",
4
4
  "license": "MIT",
5
5
  "repository": "git@github.com:weirongxu/oxlint-config-base.git",
6
6
  "files": [
@@ -36,9 +36,9 @@
36
36
  "zod": "^4.6.5"
37
37
  },
38
38
  "peerDependencies": {
39
- "oxfmt": "*",
40
- "oxlint": "*",
41
- "oxlint-tsgolint": "*"
39
+ "oxfmt": ">=0.68.0 <1.0.0",
40
+ "oxlint": "^1.83.0",
41
+ "oxlint-tsgolint": "^7.0.2001"
42
42
  },
43
43
  "optionalDependencies": {
44
44
  "zod": "^4.6.5"
package/readme.md CHANGED
@@ -3,11 +3,15 @@
3
3
  ## Install
4
4
 
5
5
  ```
6
- npm install @raidou/oxlint-config-base oxlint oxlint-tsgolint oxfmt
6
+ npm install -D @raidou/oxlint-config-base
7
7
  ```
8
8
 
9
+ `oxlint`, `oxlint-tsgolint` and `oxfmt` are declared as peer dependencies and installed automatically by npm 7+.
10
+
9
11
  ## Usage
10
12
 
13
+ ### oxlint
14
+
11
15
  oxlint.config.ts
12
16
 
13
17
  ```typescript
@@ -20,3 +24,14 @@ export default defineConfig({
20
24
  extends: [config],
21
25
  })
22
26
  ```
27
+
28
+ ### oxfmt
29
+
30
+ oxfmt.config.ts
31
+
32
+ ```typescript
33
+ import { defineConfig } from 'oxfmt'
34
+ import { fmtconfig } from '@raidou/oxlint-config-base'
35
+
36
+ export default defineConfig(fmtconfig)
37
+ ```