Closed
Description
What version of Elysia is running?
1.2.6
What platform is your computer?
Linux 6.9.7-arch1-1 x86_64 unknown
What steps can reproduce the bug?
const schema = t.Object({
test: t.Literal('hello'),
});
new Elysia()
.model({schema})
.get('/', () => {test: 'hello'},
{
response: t.Ref<typeof schema>('#/components/schemas/schema')
}
).listen(3000));
What is the expected behavior?
The $ref
should not be a child of 200
.
What do you see instead?
Additional information
Workaround: wrap the response in t.Object
, e.g t.Object({result: t.Ref<typeof schema>('#/components/schemas/schema') })
Have you try removing the node_modules
and bun.lockb
and try again yet?
No response