@cocopalm/oxc-formatter-config 0.0.16 → 0.0.22

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 (3) hide show
  1. package/README.ko.md +87 -0
  2. package/README.md +19 -19
  3. package/package.json +3 -2
package/README.ko.md ADDED
@@ -0,0 +1,87 @@
1
+ # oxc-formatter-config
2
+
3
+ [English](./README.md) | [한국어](./README.ko.md)
4
+
5
+ 이 패키지는 Prettier와 oxc 플러그인(`@prettier/plugin-oxc`)을 사용한 코드 포맷팅 설정을 제공합니다.
6
+
7
+ ## Installation
8
+
9
+ ```bash
10
+ pnpm add -D prettier @prettier/plugin-oxc @cocopalm/oxc-formatter-config
11
+ ```
12
+
13
+ ## How to use
14
+
15
+ ### .prettierrc.mjs 설정하기
16
+
17
+ 프로젝트 루트 디렉토리에 `.prettierrc.mjs` 파일을 생성합니다.
18
+
19
+ ```bash
20
+ touch .prettierrc.mjs
21
+ ```
22
+
23
+ 설정 파일에서 `@cocopalm/oxc-formatter-config`를 불러옵니다.
24
+
25
+ ```js
26
+ // .prettierrc.mjs
27
+
28
+ import config from '@cocopalm/oxc-formatter-config'
29
+
30
+ export default config
31
+ ```
32
+
33
+ `package.json` 에 포맷팅 스크립트를 추가해주세요.
34
+
35
+ ```json
36
+ // package.json
37
+
38
+ {
39
+ "scripts": {
40
+ "format": "prettier . --write",
41
+ "format:check": "prettier . --check"
42
+ }
43
+ }
44
+ ```
45
+
46
+ ### Config Override
47
+
48
+ 기본 설정을 오버라이드하고 싶다면 다음과 같이 설정을 확장할 수 있습니다.
49
+
50
+ ```js
51
+ // .prettierrc.mjs
52
+
53
+ import baseConfig from '@cocopalm/oxc-formatter-config'
54
+
55
+ /**
56
+ * @see https://prettier.io/docs/configuration
57
+ * @type {import("prettier").Config}
58
+ */
59
+ const config = {
60
+ ...baseConfig,
61
+ // 여기에 오버라이딩 설정을 작성할 수 있습니다.
62
+ printWidth: 100,
63
+ semi: true,
64
+ }
65
+
66
+ export default config
67
+ ```
68
+
69
+
70
+ <br />
71
+
72
+ ## Formatter Options
73
+
74
+ 이 패키지에 적용된 기본 포맷팅 옵션은 다음과 같습니다:
75
+
76
+ | 옵션 | 값 | 설명 |
77
+ | --------------- | -------- | -------------------------------------- |
78
+ | printWidth | 80 | 한 줄의 최대 길이 |
79
+ | tabWidth | 2 | 들여쓰기 공백 수 |
80
+ | useTabs | false | 탭 대신 공백 사용 |
81
+ | semi | false | 문장 끝 세미콜론 제거 |
82
+ | singleQuote | true | 작은따옴표 사용 |
83
+ | trailingComma | 'all' | 가능한 모든 곳에 trailing comma 추가 |
84
+ | arrowParens | 'always' | 화살표 함수 매개변수에 항상 괄호 사용 |
85
+ | plugins | [@prettier/plugin-oxc] | OXC 플러그인 사용 |
86
+
87
+ <br />
package/README.md CHANGED
@@ -1,6 +1,8 @@
1
1
  # oxc-formatter-config
2
2
 
3
- > Prettier with OXC plugin을 사용한 코드 포맷팅 설정
3
+ [English](./README.md) | [한국어](./README.ko.md)
4
+
5
+ This package provides code formatting configuration using Prettier and the oxc plugin (`@prettier/plugin-oxc`).
4
6
 
5
7
  ## Installation
6
8
 
@@ -10,17 +12,15 @@ pnpm add -D prettier @prettier/plugin-oxc @cocopalm/oxc-formatter-config
10
12
 
11
13
  ## How to use
12
14
 
13
- 패키지는 Prettier의 OXC 플러그인(`@prettier/plugin-oxc`)을 사용하여 코드를 포맷팅합니다.
14
-
15
- ### .prettierrc.mjs 설정하기
15
+ ### Setting up .prettierrc.mjs
16
16
 
17
- 프로젝트 루트 디렉토리에 `.prettierrc.mjs` 파일을 생성합니다.
17
+ Create a `.prettierrc.mjs` file in your project root directory.
18
18
 
19
19
  ```bash
20
20
  touch .prettierrc.mjs
21
21
  ```
22
22
 
23
- 설정 파일에서 `@cocopalm/oxc-formatter-config`를 불러옵니다.
23
+ Import `@cocopalm/oxc-formatter-config` in your configuration file.
24
24
 
25
25
  ```js
26
26
  // .prettierrc.mjs
@@ -30,7 +30,7 @@ import config from '@cocopalm/oxc-formatter-config'
30
30
  export default config
31
31
  ```
32
32
 
33
- `package.json` 에 포맷팅 스크립트를 추가해주세요.
33
+ Add formatting scripts to your `package.json`.
34
34
 
35
35
  ```json
36
36
  // package.json
@@ -45,7 +45,7 @@ export default config
45
45
 
46
46
  ### Config Override
47
47
 
48
- 기본 설정을 오버라이드하고 싶다면 다음과 같이 설정을 확장할 있습니다.
48
+ If you want to override the default settings, you can extend the configuration as follows.
49
49
 
50
50
  ```js
51
51
  // .prettierrc.mjs
@@ -58,7 +58,7 @@ import baseConfig from '@cocopalm/oxc-formatter-config'
58
58
  */
59
59
  const config = {
60
60
  ...baseConfig,
61
- // 여기에 오버라이딩 설정을 작성할 수 있습니다.
61
+ // Add your custom overrides here.
62
62
  printWidth: 100,
63
63
  semi: true,
64
64
  }
@@ -71,17 +71,17 @@ export default config
71
71
 
72
72
  ## Formatter Options
73
73
 
74
- 패키지에 적용된 기본 포맷팅 옵션은 다음과 같습니다:
74
+ The default formatting options applied in this package are as follows:
75
75
 
76
- | 옵션 | | 설명 |
76
+ | Option | Value | Description |
77
77
  | --------------- | -------- | -------------------------------------- |
78
- | printWidth | 80 | 줄의 최대 길이 |
79
- | tabWidth | 2 | 들여쓰기 공백 |
80
- | useTabs | false | 대신 공백 사용 |
81
- | semi | false | 문장 세미콜론 제거 |
82
- | singleQuote | true | 작은따옴표 사용 |
83
- | trailingComma | 'all' | 가능한 모든 곳에 trailing comma 추가 |
84
- | arrowParens | 'always' | 화살표 함수 매개변수에 항상 괄호 사용 |
85
- | plugins | [@prettier/plugin-oxc] | OXC 플러그인 사용 |
78
+ | printWidth | 80 | Maximum line length |
79
+ | tabWidth | 2 | Number of spaces for indentation |
80
+ | useTabs | false | Use spaces instead of tabs |
81
+ | semi | false | Omit semicolons at the end of statements |
82
+ | singleQuote | true | Use single quotes |
83
+ | trailingComma | 'all' | Add trailing commas wherever possible |
84
+ | arrowParens | 'always' | Always wrap arrow function parameters in parentheses |
85
+ | plugins | [@prettier/plugin-oxc] | Use OXC plugin |
86
86
 
87
87
  <br />
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cocopalm/oxc-formatter-config",
3
- "version": "0.0.16",
3
+ "version": "0.0.22",
4
4
  "description": "oxc formatter configuration",
5
5
  "author": "puffcocos",
6
6
  "license": "MIT",
@@ -20,7 +20,8 @@
20
20
  "url": "https://github.com/puffcocos/oxc-config-kit"
21
21
  },
22
22
  "publishConfig": {
23
- "access": "public"
23
+ "access": "public",
24
+ "provenance": true
24
25
  },
25
26
  "devDependencies": {
26
27
  "prettier": "^3.7.4",