Skip to content

Commit

Permalink
🎉 feat: release
Browse files Browse the repository at this point in the history
  • Loading branch information
SaltyAom committed Feb 1, 2025
1 parent fe00d71 commit 160bf0e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 20 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# 1.2.4 - 9 Jan 2024
Bug fix:
- Support Elysia 1.2.11
- [#23](https://github.com/elysiajs/node/issues/23) Response body object should not be disturbed or locked
- [#15](https://github.com/elysiajs/node/issues/15) Possibly fix `ReadableStream` duplex issue?
- [#14](https://github.com/elysiajs/node/issues/14) ReadableStream has already been used if request is reference multiple time

Expand Down
24 changes: 4 additions & 20 deletions example/c.ts
Original file line number Diff line number Diff line change
@@ -1,27 +1,11 @@
import { Elysia } from 'elysia'
import { Elysia, t } from 'elysia'
import { node } from '../src'
import cors from '@elysiajs/cors'

const app = new Elysia({
adapter: node()
})
.use(
cors({
origin: true,
credentials: true,
preflight: true
})
)
.post('/', ({ body }) => body)
.listen(8000, ({ port }) => {
console.log(`Server is running on http://localhost:${port}`)

fetch('http://localhost:8000', {
headers: {
authorization: `Bearer 12345`
}
})
.use(cors())
.get('/home', () => {
return 'Home'
})

// console.log(app._handle.toString())
// console.log(app.routes[0].compile().toString())

0 comments on commit 160bf0e

Please sign in to comment.