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
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ lib
dist

.DS_Store
test_static_files/
test_static_files/
7 changes: 7 additions & 0 deletions .oxfmtrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"$schema": "./node_modules/oxfmt/configuration_schema.json",
"ignorePatterns": [],
"singleQuote": true,
"semi": false,
"useTabs": true
}
40 changes: 40 additions & 0 deletions .oxlintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"$schema": "./node_modules/oxlint/configuration_schema.json",
"plugins": null,
"categories": {},
"rules": {},
"settings": {
"jsx-a11y": {
"polymorphicPropName": null,
"components": {},
"attributes": {}
},
"next": {
"rootDir": []
},
"react": {
"formComponents": [],
"linkComponents": [],
"version": null,
"componentWrapperFunctions": []
},
"jsdoc": {
"ignorePrivate": false,
"ignoreInternal": false,
"ignoreReplacesDocs": true,
"overrideReplacesDocs": true,
"augmentsExtendsReplacesDocs": false,
"implementsReplacesDocs": false,
"exemptDestructuredRootsFromChecks": false,
"tagNamePreference": {}
},
"vitest": {
"typecheck": false
}
},
"env": {
"builtin": true
},
"globals": {},
"ignorePatterns": []
}
44 changes: 0 additions & 44 deletions biome.json

This file was deleted.

59 changes: 40 additions & 19 deletions bun.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

16 changes: 8 additions & 8 deletions lefthook.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
commit-msg:
commands:
conventional:
run: bun commitlint --edit $1
commands:
conventional:
run: bun commitlint --edit $1

pre-commit:
parallel: true
commands:
check:
glob: '*.{js,ts,jsx,tsx}'
run: bun biome check --no-errors-on-unmatched --files-ignore-unknown=true {staged_files}
parallel: true
commands:
check:
glob: '*.{js,ts,jsx,tsx}'
run: bun oxlint check {staged_files}
19 changes: 10 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,21 @@
"workspaces": [
"packages/*"
],
"scripts": {
"build:wobe": "bun --filter './packages/wobe' build",
"ci": "bun build:wobe && bun --filter './packages/*' ci",
"format": "bun --filter './packages/*' format && oxfmt --write ./*.json",
"lint": "bun --filter './packages/*' lint",
"pre:commit": "oxlint ./packages && oxfmt --write ./packages",
"squash": "base_branch=${1:-main} && git fetch origin $base_branch && branch=$(git branch --show-current) && git checkout $branch && git reset $(git merge-base origin/$base_branch $branch) && git add -A"
},
"devDependencies": {
"@biomejs/biome": "2.3.4",
"@commitlint/cli": "19.3.0",
"@commitlint/config-conventional": "19.2.2",
"@types/bun": "1.3.2",
"lefthook": "1.6.10",
"oxfmt": "0.28.0",
"oxlint": "1.43.0",
"typescript": "5.9.3"
},
"scripts": {
"build:wobe": "bun --filter './packages/wobe' build",
"ci": "bun build:wobe && bun --filter './packages/*' ci",
"format": "bun --filter './packages/*' format && biome format --write ./*.json",
"lint": "bun --filter './packages/*' lint",
"pre:commit": "biome lint ./packages --no-errors-on-unmatched && biome format --write ./packages",
"squash": "base_branch=${1:-main} && git fetch origin $base_branch && branch=$(git branch --show-current) && git checkout $branch && git reset $(git merge-base origin/$base_branch $branch) && git add -A"
}
}
Empty file removed packages/wobe-benchmark/index.ts
Empty file.
24 changes: 12 additions & 12 deletions packages/wobe-benchmark/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,25 +2,25 @@
"name": "wobe-benchmark",
"version": "0.1.0",
"main": "index.ts",
"scripts": {
"bench:startup": "bun run startup/benchmark.ts",
"bench:router": "bun run router/benchmark.ts",
"bench:extracter": "bun run pathExtract/benchmark.ts",
"bench:findHook": "bun run findHook/benchmark.ts",
"lint": "oxlint . ",
"format": "oxfmt --write ."
},
"dependencies": {
"wobe": "*"
},
"devDependencies": {
"@koa/router": "15.0.0",
"@sinclair/typebox": "0.34.41",
"elysia": "1.4.18",
"find-my-way": "9.3.0",
"get-port": "7.1.0",
"mitata": "1.0.34",
"hono": "4.10.7",
"@koa/router": "15.0.0",
"radix3": "1.1.2",
"find-my-way": "9.3.0"
},
"scripts": {
"bench:startup": "bun run startup/benchmark.ts",
"bench:router": "bun run router/benchmark.ts",
"bench:extracter": "bun run pathExtract/benchmark.ts",
"bench:findHook": "bun run findHook/benchmark.ts",
"lint": "biome lint . --no-errors-on-unmatched",
"format": "biome format --write ."
"mitata": "1.0.34",
"radix3": "1.1.2"
}
}
4 changes: 1 addition & 3 deletions packages/wobe-benchmark/pathExtract/benchmark.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,7 @@ const routes: Array<RouteInterface> = [
hasParams: false,
},
{
request: new Request(
'https://localhost:3000/very/deeply/nested/route/hello/there',
),
request: new Request('https://localhost:3000/very/deeply/nested/route/hello/there'),
hasParams: false,
},
{
Expand Down
5 changes: 1 addition & 4 deletions packages/wobe-benchmark/router/hono.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,7 @@ import { RegExpRouter } from 'hono/router/reg-exp-router'
import { TrieRouter } from 'hono/router/trie-router'
import { SmartRouter } from 'hono/router/smart-router'

const createHonoRouter = (
name: string,
router: Router<unknown>,
): RouterInterface => {
const createHonoRouter = (name: string, router: Router<unknown>): RouterInterface => {
for (const route of routes) {
router.add(route.method, route.pathToCompile, handler)
}
Expand Down
9 changes: 2 additions & 7 deletions packages/wobe-benchmark/router/wobe.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,7 @@ import { UrlPatternRouter, type Router } from 'wobe'

const createWobeRouter = (name: string, radixTree: Router) => {
for (const route of routes) {
radixTree.addRoute(route.method, route.pathToCompile, () =>
Promise.resolve(),
)
radixTree.addRoute(route.method, route.pathToCompile, () => Promise.resolve())
}

radixTree.optimizeTree()
Expand All @@ -18,7 +16,4 @@ const createWobeRouter = (name: string, radixTree: Router) => {
}
}

export const wobeRouter = createWobeRouter(
'UrlPattern router',
new UrlPatternRouter(),
)
export const wobeRouter = createWobeRouter('UrlPattern router', new UrlPatternRouter())
28 changes: 14 additions & 14 deletions packages/wobe-graphql-apollo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,33 +2,33 @@
"name": "wobe-graphql-apollo",
"version": "1.0.11",
"description": "Apollo GraphQL server for Wobe (official)",
"keywords": [
"graphql-apollo",
"wobe"
],
"homepage": "https://wobe.dev",
"license": "MIT",
"author": {
"name": "coratgerl",
"url": "https://github.com/coratgerl"
},
"keywords": [
"graphql-apollo",
"wobe"
],
"repository": {
"type": "git",
"url": "https://github.com/palixir/wobe"
},
"license": "MIT",
"main": "dist/index.js",
"devDependencies": {
"get-port": "7.0.0",
"wobe": "workspace:*"
},
"dependencies": {
"@apollo/server": "5.2.0"
},
"scripts": {
"build": "bun build --minify --outdir dist $(pwd)/src/index.ts --target=bun --external=* && bun generate:types",
"generate:types": "bun tsc --project .",
"format": "biome format --write .",
"lint": "biome lint . --no-errors-on-unmatched ",
"format": "oxfmt --write .",
"lint": "oxlint . ",
"ci": "bun lint $(pwd) && bun test src"
},
"dependencies": {
"@apollo/server": "5.2.0"
},
"devDependencies": {
"get-port": "7.0.0",
"wobe": "workspace:*"
}
}
Loading