@blastlabs/utils 1.19.0 → 1.20.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blastlabs/utils",
3
- "version": "1.19.0",
3
+ "version": "1.20.0",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -21,34 +21,15 @@ paths:
21
21
  user-profile/
22
22
  use-user-data/
23
23
  button-group.tsx
24
+ user-card.tsx
25
+ login-form.tsx
24
26
 
25
27
  ❌ bad
26
28
  UserProfile/
27
29
  useUserData/
28
30
  buttonGroup.tsx
29
- ```
30
-
31
- ### 예외: React 컴포넌트
32
-
33
- **컴포넌트 파일은 `PascalCase` 사용**
34
-
35
- ```
36
- components/
37
- ✅ ButtonGroup.tsx
38
- ✅ UserProfile.tsx
39
- ✅ FormInput.tsx
40
-
41
- ❌ button-group.tsx
42
- ❌ user-profile.tsx
43
- ```
44
-
45
- **단, 폴더는 `kebab-case`**
46
-
47
- ```
48
- components/
49
- button-group/
50
- ButtonGroup.tsx
51
- ButtonGroup.test.tsx
31
+ UserCard.tsx
32
+ LoginForm.tsx
52
33
  ```
53
34
 
54
35
  ### Hooks
@@ -85,8 +66,8 @@ model/
85
66
  **대상 파일명 + `.test.` + 확장자**
86
67
 
87
68
  ```
88
- ButtonGroup.tsx → ButtonGroup.test.tsx
89
- useUserData.ts → useUserData.test.ts
69
+ button-group.tsx → button-group.test.tsx
70
+ use-user-data.ts → use-user-data.test.ts
90
71
  api.ts → api.test.ts
91
72
  ```
92
73
 
@@ -106,19 +87,20 @@ src/
106
87
  │ │ ├── use-user-query.ts
107
88
  │ │ └── user.test.ts
108
89
  │ └── ui/
109
- │ ├── UserCard.tsx # PascalCase
110
- │ └── UserCard.test.tsx
90
+ │ ├── user-card.tsx
91
+ │ └── user-card.test.tsx
111
92
  ├── features/
112
93
  │ └── auth-login/ # kebab-case
113
94
  │ ├── model/
114
95
  │ ├── api/
115
96
  │ └── ui/
116
- └── LoginForm.tsx # PascalCase
97
+ ├── login-form.tsx
98
+ │ └── login-form.test.tsx
117
99
  ├── shared/
118
100
  │ └── ui/
119
101
  │ └── button/ # kebab-case
120
- │ ├── Button.tsx # PascalCase
121
- │ └── Button.test.tsx
102
+ │ ├── button.tsx
103
+ │ └── button.test.tsx
122
104
  ```
123
105
 
124
106
  ## 변수/함수 네이밍
@@ -206,7 +188,7 @@ enum userRole {
206
188
 
207
189
  ## 중요
208
190
 
209
- - **Always** use kebab-case for files and folders
210
- - **Always** use PascalCase for component files
191
+ - **Always** use kebab-case for all files and folders (including components)
211
192
  - **Always** use camelCase for variables and functions
212
- - **Always** use UPPER_SNAKE_CASE for constants
193
+ - **Always** use UPPER_SNAKE_CASE for constants
194
+ - **Always** use PascalCase for types, interfaces, enums, and React component exports