You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CLAUDE.md
+10-2Lines changed: 10 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,6 +9,7 @@ Masto.js is a universal Mastodon API client for JavaScript/TypeScript that works
9
9
## Development Commands
10
10
11
11
### Building
12
+
12
13
```bash
13
14
npm run build # Build both ESM and CJS outputs
14
15
npm run build:esm # Build ESM only
@@ -18,6 +19,7 @@ npm run build:cjs # Build CJS only
18
19
The build process uses `tsconfig-to-dual-package` to generate dual ESM/CJS outputs from separate TypeScript configs.
19
20
20
21
### Testing
22
+
21
23
```bash
22
24
npm test# Run all tests (unit + e2e)
23
25
npm run test:unit # Run unit tests only (uses Vitest)
@@ -27,18 +29,21 @@ npm run test:e2e # Run e2e tests only (requires Mastodon instance)
27
29
**Important**: E2E tests require a local Mastodon instance running at `http://localhost:3000` with admin credentials (`admin@localhost` / `mastodonadmin`). The test setup automatically creates OAuth apps and tokens, caching them in `node_modules/.cache/masto/`.
28
30
29
31
### Linting
32
+
30
33
```bash
31
34
npm run lint # Run all linters
32
35
npm run lint:eslint # Run ESLint only
33
36
npm run lint:spellcheck # Run spellcheck only
34
37
```
35
38
36
39
### Documentation
40
+
37
41
```bash
38
42
npm run docs:build # Generate TypeDoc documentation
39
43
```
40
44
41
45
### Running Single Tests
46
+
42
47
```bash
43
48
npx vitest --project unit src/path/to/file.spec.ts
0 commit comments