@ait-co/devtools 0.0.2 → 0.0.3
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/README.md +14 -6
- package/dist/mock/index.d.ts +471 -434
- package/dist/mock/index.d.ts.map +1 -0
- package/dist/mock/index.js +1002 -427
- package/dist/mock/index.js.map +1 -1
- package/dist/panel/index.d.ts +3 -1
- package/dist/panel/index.d.ts.map +1 -0
- package/dist/panel/index.js +1221 -679
- package/dist/panel/index.js.map +1 -1
- package/dist/unplugin/index.cjs +68 -73
- package/dist/unplugin/index.cjs.map +1 -1
- package/dist/unplugin/index.d.cts +1367 -23
- package/dist/unplugin/index.d.cts.map +1 -0
- package/dist/unplugin/index.d.ts +1367 -23
- package/dist/unplugin/index.d.ts.map +1 -0
- package/dist/unplugin/index.js +59 -44
- package/dist/unplugin/index.js.map +1 -1
- package/package.json +16 -14
- package/dist/chunk-6PPZTREF.js +0 -569
- package/dist/chunk-6PPZTREF.js.map +0 -1
package/README.md
CHANGED
|
@@ -19,7 +19,13 @@ npm install -D @ait-co/devtools
|
|
|
19
19
|
pnpm add -D @ait-co/devtools
|
|
20
20
|
```
|
|
21
21
|
|
|
22
|
-
> `@apps-in-toss/web-framework
|
|
22
|
+
> **지원 SDK 버전**: `@apps-in-toss/web-framework >=2.4.0 <2.4.8` (peer, required).
|
|
23
|
+
>
|
|
24
|
+
> devtools는 위 범위의 SDK 버전에서만 동작이 검증됩니다. 범위 밖 SDK를 설치하면
|
|
25
|
+
> 패키지 매니저가 install-time에 peer 경고를 표시합니다. 또한 devtools가 아직 mock하지
|
|
26
|
+
> 않은 API를 호출하면 런타임에 에러가 발생합니다 — "devtools에서는 잘 되는데 실제 SDK에서는
|
|
27
|
+
> 안 되는" 상황을 방지하기 위한 의도적 동작입니다. 누락된 API는
|
|
28
|
+
> [이슈](https://github.com/apps-in-toss-community/devtools/issues)로 알려주세요.
|
|
23
29
|
|
|
24
30
|
## 번들러 설정
|
|
25
31
|
|
|
@@ -507,12 +513,14 @@ type _AppLogin = Assert<typeof Mock.appLogin, typeof Original.appLogin>;
|
|
|
507
513
|
// 40+ 타입 호환성 assertion
|
|
508
514
|
```
|
|
509
515
|
|
|
510
|
-
### 2. Proxy
|
|
516
|
+
### 2. Proxy 트립와이어 (런타임 차단)
|
|
511
517
|
|
|
512
|
-
`createMockProxy()
|
|
518
|
+
`createMockProxy()`는 미구현 API 접근 시 즉시 `Error`를 throw합니다. mock에 없는 API가 실 SDK에는 있을 수 있어 "devtools에서는 잘 되는데 실제 SDK에서는 안 되는" 배포 사고를 원천 차단하기 위한 의도적 동작입니다. 누락된 API는 [이슈](https://github.com/apps-in-toss-community/devtools/issues)로 제보하거나 직접 mock을 추가해 주세요.
|
|
513
519
|
|
|
514
520
|
```
|
|
515
|
-
[@ait-co/devtools] IAP.newMethod is not mocked
|
|
521
|
+
[@ait-co/devtools] IAP.newMethod is not mocked. This API may exist in
|
|
522
|
+
@apps-in-toss/web-framework, but devtools' mock does not cover it yet.
|
|
523
|
+
Please file an issue: https://github.com/apps-in-toss-community/devtools/issues
|
|
516
524
|
```
|
|
517
525
|
|
|
518
526
|
### 3. GitHub Actions 주간 CI
|
|
@@ -541,9 +549,9 @@ pnpm test # 전체 테스트 실행
|
|
|
541
549
|
|
|
542
550
|
## Troubleshooting
|
|
543
551
|
|
|
544
|
-
### `[@ait-co/devtools] XXX.method is not mocked
|
|
552
|
+
### `[@ait-co/devtools] XXX.method is not mocked` 에러가 날 때
|
|
545
553
|
|
|
546
|
-
사용 중인 SDK API가 아직 mock으로 구현되지 않았습니다.
|
|
554
|
+
사용 중인 SDK API가 아직 mock으로 구현되지 않았습니다. devtools는 "잘 되는 척" 배포를 막기 위해 미구현 API 접근 시 throw합니다. [이슈를 등록](https://github.com/apps-in-toss-community/devtools/issues)하거나 직접 mock을 추가한 뒤 다시 실행하세요.
|
|
547
555
|
|
|
548
556
|
### DevTools Panel이 안 보일 때
|
|
549
557
|
|