Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
60 commits
Select commit Hold shift + click to select a range
b1dafb9
chore: agents.md
sadcitizen Jun 7, 2026
1335d56
feat(http): package init
sadcitizen Jun 7, 2026
c2ca9ea
feat(http): add constants
sadcitizen Jun 8, 2026
6056295
feat(http): add basic errors
sadcitizen Jun 9, 2026
4775f96
feat(http): empty parse error
sadcitizen Jun 12, 2026
c088370
feat(http): types
sadcitizen Jun 20, 2026
a59d9cd
feat(http): wip
sadcitizen Jun 20, 2026
d1a0500
feat(http): wip
sadcitizen Jun 20, 2026
13e32ec
feat(http): wip
sadcitizen Jun 20, 2026
f885bfb
feat(http): wip
sadcitizen Jun 20, 2026
ac6acb2
feat(http): add tests
sadcitizen Jun 20, 2026
041ec75
feat(http): wip
sadcitizen Jun 20, 2026
8a81c58
feat(http): add request builder error codes
sadcitizen Jul 11, 2026
84425b3
feat(http): add executor type
sadcitizen Jul 11, 2026
368b9ac
feat(http): wip
sadcitizen Jul 12, 2026
613b4ba
feat(http): wip
sadcitizen Jul 12, 2026
b90a047
feat(http): wip
sadcitizen Jul 18, 2026
19ec934
feat(http): wip
sadcitizen Jul 18, 2026
65c17d1
feat(http): wip
sadcitizen Jul 21, 2026
dc5e5b8
feat(http): add prod config
sadcitizen Aug 19, 2026
1137ed6
feat(http): publish config
sadcitizen Aug 19, 2026
640700b
feat(http): move utilities
sadcitizen Aug 19, 2026
14c13ce
feat(http): move utilities
sadcitizen Aug 19, 2026
f260935
feat(http): update errors
sadcitizen Aug 19, 2026
95c27c6
feat(http): update errors
sadcitizen Aug 19, 2026
0ca0154
feat(http): add guards
sadcitizen Aug 19, 2026
560067a
feat(http): fix build
sadcitizen Aug 19, 2026
0e31d1b
feat(http): coerce to number
sadcitizen Aug 19, 2026
4261487
feat(http): remove connect and trace
sadcitizen Aug 19, 2026
bbcb372
feat(http): add default params
sadcitizen Aug 19, 2026
269d066
feat(http): support formData and stream
sadcitizen Aug 19, 2026
688af93
feat(http): improve error handling
sadcitizen Aug 19, 2026
a5bf1c1
feat(http): improve adapters
sadcitizen Aug 19, 2026
687189c
feat(http): add assert
sadcitizen Aug 19, 2026
3a5568c
feat(http): ref
sadcitizen Aug 19, 2026
19b3aa8
feat(http): fetch is default adapter
sadcitizen Aug 20, 2026
dcbfe03
feat(http): serialize params
sadcitizen Aug 21, 2026
e8478ee
feat(http): improve errors
sadcitizen Aug 21, 2026
1a05919
feat(http): add cors handling
sadcitizen Aug 21, 2026
4652d23
feat(http): add specific adapter options
sadcitizen Aug 21, 2026
4fac4b9
feat(http): fix issues
sadcitizen Aug 21, 2026
944083d
feat(http): delete comments
sadcitizen Aug 21, 2026
503e4d1
feat(http): add todo
sadcitizen Aug 21, 2026
8d1fc85
feat(http): add decisions
sadcitizen Aug 21, 2026
5980ea2
feat(http): merge headers
sadcitizen Aug 21, 2026
054e943
feat(http): translate comments
sadcitizen Aug 21, 2026
fb63925
feat(http): fix fetch adapter
sadcitizen Aug 21, 2026
f7ad1a3
feat(http): fix issue
sadcitizen Aug 21, 2026
cb518e3
feat(http): wip
sadcitizen Aug 21, 2026
e985ff1
feat(http): fix issue
sadcitizen Aug 22, 2026
f0554c5
feat(http): fix issues
sadcitizen Aug 22, 2026
778aee9
feat(http): type body
sadcitizen Aug 23, 2026
ed6b87a
feat(http): type of error
sadcitizen Aug 25, 2026
bbb75f5
feat(http): handle uploading and downloading progress
sadcitizen Aug 25, 2026
1492c73
feat(http): clean up
sadcitizen Aug 25, 2026
42d1fa5
feat(http): update agents.md
sadcitizen Aug 25, 2026
98b4a22
feat(http): prepare to publish
sadcitizen Aug 25, 2026
6d73e04
feat(http): prepare to publish
sadcitizen Aug 25, 2026
3dd8366
feat(http): update readme.md
sadcitizen Aug 25, 2026
749a034
feat(http): validate status
sadcitizen Aug 26, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
93 changes: 93 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
# AGENTS.md

## Monorepo structure

Turborepo + npm workspaces. Each component, hook, service, and style package is a separate npm package under `@byndyusoft-ui/` scope.

| Directory | Purpose | Build tool |
| -------------- | ------------------------------------------------------------- | ----------------------------------------- |
| `components/*` | React UI components | Rollup (`rollup --config`) |
| `hooks/*` | React hooks | tsc (`tsc --project tsconfig.build.json`) |
| `packages/*` | Shared types (`@byndyusoft-ui/types`) | tsc |
| `services/*` | Service packages (e.g. local-storage) | tsc |
| `styles/*` | CSS/style utilities (reset-css, keyframes-css, css-utilities) | Rollup |

Package entry point is always `src/index.ts`, built output goes to `dist/`.

## Commands

```bash
npm install # install deps
npx postinstall # init husky git hooks (also runs automatically on npm install)
npm run build # clean + build all packages via turbo (must run after npm install)
npm start # storybook dev server on localhost:6009
npm test # vitest run with typecheck (all workspaces)
npm run test:watch # vitest watch with typecheck
npm run lint:check # eslint + stylelint + prettier check (all packages)
npm run lint:fix # eslint + stylelint + prettier fix (all packages)
npm run prettier:check # prettier check only
npm run prettier:fix # prettier fix only
npm run eslint:check # eslint only
npm run eslint:fix # eslint fix only
npm run stylelint:check # stylelint only
npm run stylelint:fix # stylelint fix only
npm run set-changes # interactive changeset creation (changeset)
npm run update-packages-versions # apply changesets (bump versions + changelogs)
npm run publish # changeset publish to npm
```

### Run a single package's tests

```bash
npm test -w <package-name>
# Example: npm test -w @byndyusoft-ui/use-timeout
```

The `<package-name>` is the npm `name` field from the package's `package.json`.

### CI order

lint:check → test → build → build-storybook

## Creating new entities

Use hygen templates:

```bash
npx hygen create component # scaffolds a new component under components/
npx hygen create hook # scaffolds a new hook under hooks/
```

Generated packages include `package.json`, `tsconfig.json`, `src/` with boilerplate, and a `rollup.config.mjs` (components) or `tsconfig.build.json` (hooks).

## Testing

- Vitest with `globals: true` and `jsdom` environment
- Test files use `*.tests.ts(x)` or `*.test.ts(x)` or `*.spec.ts(x)` patterns
- Type-check test files use `*.tests-d.ts` pattern (configured in root `vitest.config.mjs`)
- Setup: `setupTests.ts` (imports `@testing-library/jest-dom` and `vitest-localstorage-mock`)
- Packages with local `vitest.config.mjs` use `defineProject` + `mergeConfig` from root config

## Style & formatting

- Prettier: 4-space indent, single quotes, no trailing commas, 120 char width (2-space for JSON, double quotes for SCSS/CSS)
- ESLint: `@byndyusoft/eslint-config/typescript` + `typescript-style-frontend` + `react` + `react-testing` presets
- Stylelint: `@byndyusoft/stylelint-config` with SCSS extensions, `color-named` rule disabled
- Commit messages: conventional commits (enforced by `@commitlint/config-conventional`)
- Pre-commit hook: lint-staged runs prettier on staged files

## Publishing & releases

- Uses Changesets: `npm run set-changes` → `npm run update-packages-versions` → `npm run publish`
- Changesets config: `baseBranch: "master"`, `access: "public"`, `updateInternalDependencies: "patch"`
- Packages are published to npm under `@byndyusoft-ui/` scope

## Key quirks

- Root `lint-staged.config.js` has a typo: matches `{ts,tsx,js,jsx,json,css,scss,md}` without glob prefix — uses `prettier` command (not `prettier --write`), meaning it only checks, not fixes, on pre-commit
- React 17 peer dependency (not React 18)
- Node 20 required (enforced in CI and Docker build)
- Components use CSS Modules for stories (`*.module.css`) alongside SCSS for component styles (`*.scss`)
- Storybook runs on port **6009** (not the default 6006)
- ESLint config path in workspace packages references `../../eslint.config.js` — shared root config
- `eslint.config.js` overrides relax rules for test/story files (disables `no-magic-numbers`, `react/button-has-type`, `react/forbid-dom-props`, warns on `explicit-module-boundary-types`)
Loading
Loading