Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
18 changes: 3 additions & 15 deletions .claude/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,31 +16,19 @@
{
"name": "next-playground",
"runtimeExecutable": "pnpm",
"runtimeArgs": [
"--filter",
"@orpc/next-playground",
"dev"
],
"runtimeArgs": ["--filter", "@orpc/next-playground", "dev"],
"port": 3000
},
{
"name": "nest-playground",
"runtimeExecutable": "pnpm",
"runtimeArgs": [
"--filter",
"@orpc/nest-playground",
"dev"
],
"runtimeArgs": ["--filter", "@orpc/nest-playground", "dev"],
"port": 3000
},
{
"name": "cloudflare-playground",
"runtimeExecutable": "pnpm",
"runtimeArgs": [
"--filter",
"@orpc/cloudflare-playground",
"dev"
],
"runtimeArgs": ["--filter", "@orpc/cloudflare-playground", "dev"],
"port": 3000
}
]
Expand Down
17 changes: 0 additions & 17 deletions .claude/settings.json

This file was deleted.

6 changes: 2 additions & 4 deletions .github/ISSUE_TEMPLATE/1-bug-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@ body:
id: reproduction
attributes:
label: Reproduction
description:
Please link to a minimal repository that reproduces the issue.
description: Please link to a minimal repository that reproduces the issue.
A minimal repro is required unless the problem is obvious from your description.
You can create one with [oRPC Playgrounds](https://orpc.dev/docs/playgrounds).
placeholder: Reproduction
Expand All @@ -28,8 +27,7 @@ body:
id: bug-description
attributes:
label: Describe the bug
description:
Provide a clear, concise description of the bug.
description: Provide a clear, concise description of the bug.
If you plan to submit a PR to fix it, mention that here. Thanks!
placeholder: Bug description
validations:
Expand Down
3 changes: 1 addition & 2 deletions .github/ISSUE_TEMPLATE/2-feature-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ body:
id: feature-description
attributes:
label: Describe the feature
description:
A clear and concise description of what you think would be a helpful addition,
description: A clear and concise description of what you think would be a helpful addition,
including the possible use cases and alternatives you have considered.
If you have a working prototype or module that implements it, please include a link.
placeholder: Feature description
Expand Down
3 changes: 1 addition & 2 deletions .github/ISSUE_TEMPLATE/3-documentation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ body:
id: documentation-description
attributes:
label: Describe the change
description:
A clear and concise description of what you think should be changed,
description: A clear and concise description of what you think should be changed,
including the possible use cases and alternatives you have considered.
placeholder: Description
validations:
Expand Down
13 changes: 3 additions & 10 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,21 +10,14 @@ updates:
default-days: 1
versioning-strategy: increase
groups:
eslint:
patterns:
- eslint
- '@antfu/eslint-config'
- 'eslint-plugin-*'
standard-server:
patterns:
- '@standard-server/*'
openapi-spec:
patterns:
- '@openapi-spec/*'
dev-dependencies-minor-patch:
dependency-type: development
exclude-patterns:
- eslint
- '@antfu/eslint-config'
- 'eslint-plugin-*'
- compression # inline
update-types:
- minor
- patch
6 changes: 2 additions & 4 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ permissions:
contents: read

jobs:
lint_and_typecheck:
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
Expand All @@ -19,9 +19,7 @@ jobs:

- run: pnpm i

- run: pnpm run lint

- run: pnpm run type:check
- run: pnpm run check

- run: pnpm run docs:validate

Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/pullfrog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,7 @@ jobs:
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
CLAUDE_CODE_OAUTH_TOKEN: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
GOOGLE_GENERATIVE_AI_API_KEY:
${{ secrets.GOOGLE_GENERATIVE_AI_API_KEY }}
GOOGLE_GENERATIVE_AI_API_KEY: ${{ secrets.GOOGLE_GENERATIVE_AI_API_KEY }}
GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }}
XAI_API_KEY: ${{ secrets.XAI_API_KEY }}
DEEPSEEK_API_KEY: ${{ secrets.DEEPSEEK_API_KEY }}
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
!.claude/
!.agents/
!.zed/
.claude/worktrees/

# Common generated folders
logs/
Expand Down
3 changes: 3 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"recommendations": ["oxc.oxc-vscode"]
}
56 changes: 4 additions & 52 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,55 +1,7 @@
{
// Disable the default formatter, use eslint instead
"prettier.enable": false,
"editor.formatOnSave": false,

// Auto fix
"editor.defaultFormatter": "oxc.oxc-vscode",
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.fixAll.eslint": "explicit",
"source.organizeImports": "never"
},

// Silent the stylistic rules in you IDE, but still auto fix them
"eslint.rules.customizations": [
{ "rule": "style/*", "severity": "off", "fixable": true },
{ "rule": "format/*", "severity": "off", "fixable": true },
{ "rule": "*-indent", "severity": "off", "fixable": true },
{ "rule": "*-spacing", "severity": "off", "fixable": true },
{ "rule": "*-spaces", "severity": "off", "fixable": true },
{ "rule": "*-order", "severity": "off", "fixable": true },
{ "rule": "*-dangle", "severity": "off", "fixable": true },
{ "rule": "*-newline", "severity": "off", "fixable": true },
{ "rule": "*quotes", "severity": "off", "fixable": true },
{ "rule": "*semi", "severity": "off", "fixable": true }
],

// Enable eslint for all supported languages
"eslint.validate": [
"javascript",
"javascriptreact",
"typescript",
"typescriptreact",
"vue",
"html",
"markdown",
"json",
"jsonc",
"yaml",
"toml",
"xml",
"gql",
"graphql",
"astro",
"svelte",
"css",
"less",
"scss",
"pcss",
"postcss"
],

"typescript.tsdk": "node_modules/typescript/lib",
"typescript.enablePromptUseWorkspaceTsdk": true,
"typescript.preferences.autoImportFileExcludePatterns": [],
"typescript.preferences.autoImportSpecifierExcludeRegexes": []
"source.fixAll.oxc": "explicit"
}
}
53 changes: 1 addition & 52 deletions .zed/settings.json
Original file line number Diff line number Diff line change
@@ -1,55 +1,4 @@
{
"format_on_save": "on",
// Use ESLint's --fix:
"code_actions_on_format": {
"source.fixAll.eslint": true
},
"formatter": [],
// Enable eslint for all supported languages
// Defaults only include https://github.com/search?q=repo%3Azed-industries%2Fzed%20eslint_languages&type=code
"languages": {
"HTML": {
"language_servers": ["...", "eslint"]
},
"Markdown": {
"language_servers": ["...", "eslint"]
},
"Markdown-Inline": {
"language_servers": ["...", "eslint"]
},
"JSON": {
"language_servers": ["...", "eslint"]
},
"JSONC": {
"language_servers": ["...", "eslint"]
},
"YAML": {
"language_servers": ["...", "eslint"]
},
"CSS": {
"language_servers": ["...", "eslint"]
}
// Add other languages as needed
},
"lsp": {
"eslint": {
"settings": {
"workingDirectories": ["./"],

// Silent the stylistic rules in your IDE, but still auto fix them
"rulesCustomizations": [
{ "rule": "style/*", "severity": "off", "fixable": true },
{ "rule": "format/*", "severity": "off", "fixable": true },
{ "rule": "*-indent", "severity": "off", "fixable": true },
{ "rule": "*-spacing", "severity": "off", "fixable": true },
{ "rule": "*-spaces", "severity": "off", "fixable": true },
{ "rule": "*-order", "severity": "off", "fixable": true },
{ "rule": "*-dangle", "severity": "off", "fixable": true },
{ "rule": "*-newline", "severity": "off", "fixable": true },
{ "rule": "*quotes", "severity": "off", "fixable": true },
{ "rule": "*semi", "severity": "off", "fixable": true }
]
}
}
}
"formatter": [{ "code_action": "source.fixAll.oxc" }, { "language_server": { "name": "oxfmt" } }]
}
32 changes: 32 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# AGENTS.md

## Repository

oRPC: typesafe APIs with RPC and OpenAPI support, in a pnpm monorepo.

- `packages/*`: the published packages; `packages/bun` runs with `bun test`, `packages/cloudflare` with its own vitest (workerd)
- `apps/content`: the docs site (Blume)
- `tests/`: e2e tests
- `playgrounds/*`: example apps
- `benches/`: benchmarks

## Commands

```bash
pnpm install
pnpm test # per-package tests + vitest
pnpm vitest run <path> # one test file
pnpm check # lint and type check, including *.test-d.ts
pnpm fix # check, applying fixes
pnpm format # format with oxfmt
pnpm repo:fix # fix monorepo issues with sherif
pnpm docs:validate # JSDoc backlinks + docs links
pnpm bench
pnpm --filter @orpc/server prepack # build one package; tests don't need a build
```

Before finishing, run `pnpm format`, `pnpm check` and `pnpm test`. CI doesn't check formatting.

## Pull requests

Titles follow Conventional Commits, scoped by the affected packages, separated by a comma and a space: `fix(server): ...`, `fix(server, client): ...`. Use `rpc`/`openapi` for changes tied to a protocol, and `content` only with `chore`, for the docs site itself; docs about a package use its scope (`docs(openapi): ...`). Leave out the scope when the change is too broad.
29 changes: 0 additions & 29 deletions CLAUDE.md

This file was deleted.

2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ This repository uses:
- **Node.js** v22+ (use [`pnpm env`](https://pnpm.io/cli/env) for quick setup)
- **pnpm** and **pnpm workspaces** for dependency management
- **Vitest** for testing
- **ESLint** with [@antfu/eslint-config](https://github.com/antfu/eslint-config) for linting and formatting
- **oxlint** for linting and type checking (`pnpm check`), **oxfmt** for formatting (`pnpm format`)

## Workflow

Expand Down
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,11 @@ export const router = {
Then call them from a client that knows every input and output, without generating anything:

```ts
import type { RouterClient } from '@orpc/server'
import type { router } from './router'
import { createORPCClient } from '@orpc/client'
import { RPCLink } from '@orpc/client/fetch'
import type { RouterClient } from '@orpc/server'

import type { router } from './router'

const link = new RPCLink({ origin: 'http://localhost:3000', url: '/rpc' })
const client: RouterClient<typeof router> = createORPCClient(link)
Expand Down
Loading
Loading