0
0
mirror of https://github.com/honojs/hono.git synced 2024-11-28 17:22:54 +01:00
Commit Graph

69 Commits

Author SHA1 Message Date
Yusuke Wada
5f78e4e1b3
chore(lint): ESLint v9 (#3393)
* chore(lint): ESLint v9

* run prettier
2024-09-12 12:05:41 +09:00
yasuaki640
18f937d3be
chore(test): migrate to vitest v2 (#3326)
* migrate vitest v2

* re run bun i
2024-08-29 16:57:40 +09:00
Shotaro Nakamura
97ec6521a7
chore: replace tsx with Bun (#3103) 2024-07-07 15:55:19 +09:00
Yusuke Wada
786f9e2a9d
test(workerd): add tests for WebSocket (#2891) 2024-06-03 00:14:11 +09:00
Yusuke Wada
f634c82451
test(workerd): rename the runtime test wrangler to workerd (#2888)
* test(workerd): rename the runtime test `wrangler` to `workerd`

* fixed ci.yml

* fixed a typo

* use node 20.x
2024-06-02 22:49:40 +09:00
odri
366f760a30
fix(client): allow multiple files on the same key in form (#2791)
* fix(client): allow multiple files on the same key in form

* add tests and update `msw`

* fixed import order

Co-authored-by: Yusuke Wada <yusuke@kamawada.com>
2024-05-28 18:39:01 +09:00
Yusuke Wada
9890bc1157
chore: update lockfile (#2805) 2024-05-27 16:38:50 +09:00
Yusuke Wada
cc4b2b3c7f
chore(lint): update eslint rules (#2790)
* chore(lint): update eslint rules

* fix formats
2024-05-26 05:17:45 +09:00
Yusuke Wada
1b2a4c0800
feat(jsr): support JSR (#2662)
* feat(jsr): reduce slow types (#2369)

* feat(jsr): reduce slow types

* fix: use allow function

* chore: format code

* chore: denoify

* add `deno.json`

* add `jsr-dry-run` command for CI

* don't put `JSX` on `global`

* fix test settings for deno

* don't use `dynamicClass`

* don't declare `ExecutionContext` in `global`

* goodbye denoify

* exports `./middleware`

* exports `./helper`

* exports each helper and middleware

* remove the `awslambda` implementation which is not enough

* feat(jsr): remove helper.ts and middleware.ts (#2667)

* feat(jsr): remove helper.ts and middleware.ts

* fix: fix test

* dont' use `SuperClass`

Co-authored-by: Taku Amano <taku@taaas.jp>

* feat(jsr): delete `mod.ts` (#2669)

* rename `deno.json` to `jsr.json`

* lint

* remove slow type in lambda adapter

* fixed runtime test for deno

* export all utils

* add a GitHub action to publish the package to JSR

* fixed declaring `ContextVariableMap`

* fixed the type error

* include `jsr.json` in `jsr.json`

* update `jsr.json`

---------

Co-authored-by: Shotaro Nakamura <79000684+nakasyou@users.noreply.github.com>
Co-authored-by: Taku Amano <taku@taaas.jp>
2024-05-24 17:47:28 +09:00
Yusuke Wada
ab7144871b
refactor(cloudflare-workers): remove @cloudflare/workers-types (#2773)
* refactor(cloudflare-workers): remove `@cloudflare/workers-types`

* add `@denoify-ignore`

* add missing comment
2024-05-24 06:01:12 +09:00
Yusuke Wada
3126beb231
chore: bump up @hono/node-server (#2323)
* chore: bump up `@hono/node-server`

* update lock file
2024-03-07 15:37:16 +09:00
Fuxiao Peng
c9567b60e5
fix(devDependencies): Fix the problem of missing glob package (#2277)
* fix(pnpm): Fix the problem of missing glob package caused by ghost dependency in pnpm

* run `bun install`

---------

Co-authored-by: yuanrang.peng <yuanrang.peng@tuya.com>
Co-authored-by: Yusuke Wada <yusuke@kamawada.com>
2024-02-28 17:23:52 +09:00
Yusuke Wada
b24f9e38da Merge branch 'main' into v4 2024-01-29 23:44:20 +09:00
Yusuke Wada
ead3677601
chore: use Bun as a package manager (#2105)
* chore: use Bun as a package manager

* lock `np`
2024-01-29 23:27:54 +09:00
Yusuke Wada
f616ed9abe
chore(lint): set curly rule as all (#2112)
* chore(lint): set `curly` rule as `all`

* denoify
2024-01-29 22:21:09 +09:00
Yusuke Wada
4560df5efc
ci: remove lagon runtime tests and other lagon things (#1971)
* ci: remove lagon runtime tests and other lagon things

* remove lagon from github actions
2024-01-14 19:09:09 +09:00
Bruce Harrison
03b6903b96 feat(jsx-renderer): Nested Layouts via Renderer (#1945)
* setup basic test

* naive implementaton kinda working

* pass props to parent layout

* most tests passing

* tests passing

* remove files

* reset files

* reset files

* leave note

* introduce `<Layout>`

* denoify

* fixed type error

---------

Co-authored-by: Yusuke Wada <yusuke@kamawada.com>
2024-01-14 16:55:14 +09:00
watany
7f0e51a389
chore(vitest/tsconfig): bump vitest and update tsconfig.build.json (#1851)
* update vitest

* vitest typecheck

* ignore vitest setting in build

* Revert "vitest typecheck"
2023-12-25 11:46:37 +09:00
watany
8addfd442a
chore: upgrading vitest to v1.0 (#1830)
* update vitest

* vitest type
2023-12-19 07:29:30 +09:00
Yoshiaki Sugimoto
7a55399bc2
test: Use vitest for fastly compute testing (#1828)
* use vitest for fastly compute testing

* reflect reviews and solve problem

* chore: update comment

* run lint:fix
2023-12-17 21:17:18 +09:00
Yusuke Wada
f18e8f9950
chore: bump devDependencies (#1820) 2023-12-14 18:10:27 +09:00
Yusuke Wada
af9e485266
chore: bump up @hono/eslint-config (#1816) 2023-12-13 19:29:26 +09:00
Yusuke Wada
18b62821dd
chore: use @hono/eslint-config (#1815) 2023-12-13 18:35:30 +09:00
Taku Amano
fedeb3d696
feat: Introduce streaming API with Suspense and use. (#1630)
* feat(jsx): Support async component.

* chore: denoify

* feat: Support nested async components.

* chore: denoify

* Remove unintended file from commit.

* test(jsx): Add test for html tagged template strings.

* feat: Introduce streaming API with `Suspense` and `use`.

* chore: denoify

* "use" receives only Promise.

* feat: Support multiple calls and nested calls to "use".

* refactor: tweaks replacement script.

* test: Add test for replacement result of streaming

* chore: denoify

* test: Add test "Complex fallback content"

* refactor: Add "typescript-eslint/no-explicit-any".

* Use jsdom instead of happy-dom due to ci failure.

* test: update test data for suspense.

* refactor: Remove excessive exports

* refactor: Changed initialization of `useContexts[]` to clarify intent.

* perf: improve `renderToReadableStream()` performance.

* chore: denoify

* pref: Shortened the output JS a bit.

* pref: Delete unneeded condition

* docs(jsx/streaming): Add `@experimental` flag to streaming API.

* fix(jsx/streadming): fix loop when using fullfilled Promise with null or undefined.

* fix(jsx/streaming): Catch unhandledRejection to avoid streaming not being closed.

* chore(jsx/streaming): Add entries for jsx/streaming to package.json.

* chore: denoify

* feat(jsx/streaming): Support the Async Component inside Suspense.

* chore: denoify

* feat(jsx/streaming): remove implementation of `use()`.
2023-11-07 07:09:04 +09:00
Yusuke Wada
b6c0e45d5f
chore: bump up denoify (#1570) 2023-10-13 08:59:27 +09:00
Yusuke Wada
90259f3acb
test: use Node.js Native Web APIs instead of miniflare's (#1558)
* test: use Node.js Native Web APIs instead of miniflare's

* `denoify-ignore`
2023-10-10 21:32:10 +09:00
Yusuke Wada
e326208fdf
fix(context): use FetchEvent instead of FetchEventLike (#1532) 2023-10-03 23:09:16 +09:00
Derrick Farris
5b07146cf8
test(vitest): replace jest with vitest (#1404)
* test(vitest): replace `jest` with `vitest` for core tests

* test(fastly): `jest` -> `vitest`, correct env for fastly

* test(jest): remove `jest-environment-miniflare` as dep

* test(lagon): configure `lagon` tests to run on `vitest`

* test(lambda): `jest` -> `vitest`

* test(lambda-edge): `jest` -> `vitest`

* test(node): `jest` -> `vitest`

* test(wrangler): `jest` -> `vitest`

* chore(deps): remove `jest` and `ts-jest` from deps

* test(vitest): add `yarn coverage` for checking coverage

* test(fastly): fix check for `globalThis.crypto`

* test(handler): fix stray `.only`

* test(lagon): change env file back to original path

* test(fastly): go back to `jest` until `vitest` has support for fastly env

* test(fastly): remove hack for the `crypto` global from the test
2023-09-08 17:42:28 +09:00
Yusuke Wada
ee5929b045
fix(tsconfig): remove skipLibCheck (#1201) 2023-06-26 17:14:40 +09:00
Yusuke Wada
919ffa55af chore: update np 2023-05-12 16:19:07 +09:00
Yusuke Wada
db7ad68b42
chore: update eslint (#1060) 2023-05-02 18:45:21 +09:00
Yusuke Wada
ad880dba43
feat: env support enviroment variables for multi runtimes (#949)
* feat: `env` support enviroment variables for multi runtimes

* typo

* denoify

* fixed ci settings

* fixed deno command

* comment out lagon test

* remove warnings
2023-03-06 21:12:22 +09:00
Yusuke Wada
c0d2e608a6
feat: hc - Hono Client (#862) 2023-02-08 07:22:32 +09:00
Yusuke Wada
4546b40cbd chore: added missing module
(i've mistaken merging)
2023-01-19 23:06:17 +09:00
Yusuke Wada
e84ac2cffb test: add tests and CI for Node.js (#785) 2023-01-19 22:45:23 +09:00
Yusuke Wada
3cd1b1dbf4 test: add tests and CI for Fastly Compute@Edge (#783)
* test: add tests and CI for Fastly Compute@Edge

* fix detecting which runtime is fastly and add the test for it
2023-01-19 22:44:38 +09:00
Yusuke Wada
397c12e181 refactor: refactor and fix Types (#748)
* wip

* refactor: refactor and fix Types
2023-01-19 22:44:34 +09:00
Yusuke Wada
85e3c6a275 feat: new validator middleware using 3rd-party & current middleware obsolete (#745)
* feat: introduce HonoRequest with "wrapper pattern" (#733)

* feat: HonoRequest

* avoid `awaits`

* use `raw` instead of `original`

* feat: types for "RPC" support & build-in validator obsolete

* feat: introduce HonoRequest with "wrapper pattern" (#733)

* feat: HonoRequest

* avoid `awaits`

* use `raw` instead of `original`

* create generic middleare for 3rd-party validator

* indent

* support multiple validators and refactor

* remove unsed lines

* denoify
2023-01-19 22:40:13 +09:00
Yudai Nakata
8dfdba9b44
build: validate package exports after build (#824) 2023-01-19 22:32:11 +09:00
Yusuke Wada
1eb49b8d96
refactor: support new @cloudflare/worker-types (#673)
* refactor: support new `@cloudflare/worker-types`

* do not attach crypto to global

* denoify ignore serve-static for cloudlfare

* ignore the utility for cloudflare

* import types
2022-11-23 07:27:42 +09:00
Yusuke Wada
ca52dd898e
fix(build): fix ESM support in Node.js / use esbuild (#631)
* fix(build): fix ESM support in Node.js / use `esbuild`

* add tsx

* denoify ignore
2022-10-28 08:46:02 +09:00
Yusuke Wada
719ce857ec chore: bump up libraries version 2022-09-14 08:42:04 +09:00
Yusuke Wada
869ab52b42 chore: bump up jest-environment-miniflare 2022-08-20 11:43:28 +09:00
Yusuke Wada
47f7577934 chore: remove @types/mustache
It's not needed
2022-07-24 13:18:24 +09:00
Yusuke Wada
53658c2464 chore(prettier): remove markdown-nocjsp parser
Close #377
2022-07-16 10:03:01 +09:00
TANIGUCHI Masaya
fc26f1a490
feat: Add compress middleware (#386)
* Add compress middleware

* Format code

* Update order of executions

* Add test

* Remove version check

* Remove node:stream/web

* Update dependency

* Remove version check
2022-07-16 09:38:43 +09:00
Yusuke Wada
af9f6a73d9 [BREAKING] feat: remove "graphql-server" middleware, will be obsolete (#366)
It might be *third-party middleware*.

Close #357
2022-07-15 08:40:15 +09:00
Yusuke Wada
447fc3f4d6 chore: install np 2022-07-02 15:50:17 +09:00
Yusuke Wada
d9e9e62e47
feat: support Deno! (#336) 2022-07-02 15:09:45 +09:00
Yusuke Wada
34aa124405 chore: update libs 2022-06-23 23:20:56 +09:00