Skip to content

Version 1.2.0 types does not work with Elysia v1.2.9 #61

@darkyelox

Description

@darkyelox

What version of Elysia is running?

1.2.9

What platform is your computer?

Linux 6.6.65-1-MANJARO x86_64 unknown

What steps can reproduce the bug?

Install Elysia latest version, by the time of publishing this is 1.2.9, install latest version of @elysiajs/cors which is 1.2.0, just create a simple Elysia plugin:

import { Elysia } from 'elysia';
import { cors } from '@elysiajs/cors';

export const app = new Elysia()
  .use(cors({ // Here I get type errors about type missing Promise functions like then, catch, etc.
    origin: true,
  }))
  .listen(3000);

What is the expected behavior?

To use the latest version of elysia and @elysiajs/cors packages together.

What do you see instead?

I had to downgrade @elysiajs/cors to v1.1.1.

Additional information

Elysia official plugins should follow the same elysia version and publish at the same time

Have you try removing the node_modules and bun.lockb and try again yet?

Yes

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions