Yusuke Wada
a8e0bf0b48
chore: do not need await
2022-03-01 01:50:45 +09:00
Yusuke Wada
32686f4e5b
chore: update benchmark script ( #120 )
...
* chore: fix benchmark script
* update readme
2022-02-28 21:56:50 +09:00
Yusuke Wada
4822077fea
docs: update readme
2022-02-26 16:19:53 +09:00
Yusuke Wada
adb55ca052
feat: app.notFound()
and app.onError
( #117 )
2022-02-26 08:36:11 +09:00
Yusuke Wada
5de3a0c4f2
docs: update readme
2022-02-23 11:30:24 +09:00
Yusuke Wada
68baca0949
docs: add badges
2022-02-22 00:04:22 +09:00
Yusuke Wada
9de6328f87
feat: app.onError
for handling error ( #111 )
2022-02-20 22:43:14 +09:00
Yusuke Wada
49fedca6a4
feat: app.notFound
for default 404 not found ( #110 )
2022-02-20 19:59:51 +09:00
Yusuke Wada
ea329b8369
docs: update benchmark results
2022-02-18 10:25:55 +09:00
Yusuke Wada
b0b6f7f8a3
refactor: router must have only one hander ( #107 )
...
* refactor: router must have only one hander
* docs: update benchmark
2022-02-17 21:46:34 +09:00
Yusuke Wada
c5cc9f25a6
feat: nested route ( #105 )
...
# BREAKING CHANGES!!!
`app.route` is changed:
**Chained route** is obsolete:
```
app.route('/')
.get((c) => c.text('get /'))
// ^^^ Not working now!!
```
Now, `app.route` enables **nested route**:
```
const book = app.route('/book')
book.get('/', (c) => c.text('List books')) // => GET /book
book.get('/:id', (c) => {
return c.text('Get Book: ' + c.req.param('id'))) // => GET /book/:id
})
```
2022-02-16 11:06:22 +09:00
Yusuke Wada
d7fe0b0d67
tweak
2022-02-15 21:26:59 +09:00
Yusuke Wada
b9286d0f4f
docs: update readme
2022-02-15 17:19:53 +09:00
Yusuke Wada
c123d5f78d
feat: add option for no
strict routing ( #103 )
...
default is `strict`
2022-02-15 16:52:06 +09:00
Yusuke Wada
f3fbe68613
docs: update readme ( #99 )
2022-02-09 23:14:44 +09:00
Minghe
d1d790a9a8
fix(typo): flamework is framework
2022-02-07 14:44:33 +08:00
Yusuke Wada
a72660bd66
feat: auto set statusText
( #93 )
...
* refactor: context
* tweak
* feat: auto set status text
2022-02-05 22:20:34 +09:00
Yusuke Wada
7dd486ad7b
feat: builtin middleware as sub module ( #81 )
...
# BREAKING CHANGES!!
Now, builtin middleware are not in main package. You can't use `Middleware.logger()` method. Call sub modules if needed:
```js
import { Hono } from 'hono'
import { poweredBy } from 'hono/powered-by'
import { logger } from 'hono/logger'
const app = new Hono()
app.use('*', poweredBy())
app.use('*', logger())
```
Closes: #80
---
* feat: builtin middleware as sub module
* fixed middleware
* Update readme
* Add types
* New gif
2022-02-01 22:15:00 +09:00
Yusuke Wada
223429fa71
chore: tweak ( #75 )
...
* Update durable object example
* Add line to mustache readme
* Tweak
* Add comments
2022-01-30 11:33:17 +09:00
Yusuke Wada
29f67c5b72
feat: Mustache Middleware ( #72 )
...
* [WIP] feat: Mustache Middleware
Dirty code.
A Big problem is tests for Workers Site KV does not work well...
* feat: mustache middleware
* Add readme
2022-01-29 09:09:37 +09:00
Yusuke Wada
ff5a83b38b
perf: Speed up to calculate content-length ( #67 )
...
* perf: Speed up to calculate content-length
2022-01-27 09:09:54 +09:00
Yusuke Wada
336afc812d
refactor: refactor something ( #65 )
...
* chmod
* declare `parsedBody` in middleware
* Dont use any
* Rename
* rename and fixed benchmarks, update score
2022-01-26 22:11:11 +09:00
Yusuke Wada
68444b6932
feat: Add new shortcuts for request/response ( #62 )
...
* Add new shortcuts for request/response
* We have only `param`, we can not use `params`
* Update readme
* tweak
2022-01-26 13:10:05 +09:00
Yusuke Wada
7c92d55a25
feat: Error handling ( #48 )
2022-01-16 21:34:06 +09:00
Yusuke Wada
03d9dc835b
docs: fixed readme ( #45 )
...
* typo
* tweak
2022-01-13 02:29:11 +09:00
Justin Noel
56de23a723
fix: correct typo for change directory ( #44 )
2022-01-13 02:16:05 +09:00
Yusuke Wada
fceed7465a
Support module workers syntax for Cloudflare Workers ( #43 )
...
* add fetch method and modify context
* Add example of Durable Objects
* Fixed export/import style
* Update readme
* Fixed script
2022-01-12 09:20:16 +09:00
Yusuke Wada
4741fd3c4b
Feature/redirect ( #36 )
...
* Add redirect method
* Make Headers type
* Typecheck
2022-01-09 22:51:58 +09:00
Yusuke Wada
f9fa20062b
Refactor ( #35 )
...
* export Handler
* Fixed example
* Update readme
* Rename
* Param value as string
* Update jsx ssr example
* Hono is Ultrafast web framework
2022-01-09 21:10:12 +09:00
Yusuke Wada
f1117c04f2
Add worktop benchmark ( #33 )
...
* Remove package-lock.json
* Fixed for warnings
* Disable lint the line
* Update jsx-ssr example
* Add `worktop` benchmark
2022-01-09 06:07:43 +09:00
Yusuke Wada
7d4f10d995
Refactor ( #32 )
...
* Remove package-lock.json
* Fixed for warnings
* Disable lint the line
* Update jsx-ssr example
2022-01-09 05:30:50 +09:00
Yusuke Wada
83f731f259
Bumped to 0.0.12
2022-01-08 14:08:44 +09:00
Yusuke Wada
77a8ce82c8
Update README
2022-01-08 13:51:50 +09:00
Yusuke Wada
d73472cc3a
Update README
2022-01-08 09:48:22 +09:00
Yusuke Wada
00adeb7bcb
Update text
2022-01-07 17:41:11 +09:00
Yusuke Wada
c587547174
Add description for fire()
2022-01-06 05:19:16 +09:00
Yusuke Wada
2d0e7eef70
Documentation ( #24 )
...
* Create context.ts and test
* Handling TypeError
* Implemented c.json()
* Update readme and example
* Update sample code
* Update readme
* Write documents
2022-01-06 05:11:37 +09:00
Yusuke Wada
ee80ae3ae4
json method in Context ( #23 )
...
* Create context.ts and test
* Handling TypeError
* Implemented c.json()
* Update readme and example
2022-01-06 03:22:53 +09:00
Yusuke Wada
6a19e5f975
Update animation gif
2022-01-05 22:15:20 +09:00
Yusuke Wada
e6039f69f9
Migrate to TypeScript ( #21 )
...
* Migrate to TypeScript
* ready for publish
2022-01-05 18:41:29 +09:00
Yusuke Wada
303db32e66
Can use async on handler ( #16 )
2022-01-03 18:11:46 +09:00
Yusuke Wada
5db617953d
Typo
2022-01-03 03:16:02 +09:00
Yusuke Wada
b6d9eb3ad9
Add instruction ( #14 )
2022-01-02 22:46:36 +09:00
Yusuke Wada
e48bd4b4de
some fixed
2022-01-02 18:34:36 +09:00
Yusuke Wada
b589321fc2
Dont use async on middleware
2022-01-02 00:29:03 +09:00
Yusuke Wada
4eb8569cd3
Fixed example
2022-01-02 00:16:44 +09:00
Yusuke Wada
1b77b0fe20
Handle 404
2022-01-01 23:01:54 +09:00
Yusuke Wada
d501cfd6fa
Builtin Middleware!
2022-01-01 16:22:35 +09:00
Yusuke Wada
3198fa05d8
Use named import, add types by .d.ts file
2022-01-01 15:29:41 +09:00
Yusuke Wada
28e1d438f4
Update README.md
2021-12-28 21:16:27 +09:00