Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeScript rewrite #174

Closed
RedstoneWizard08 opened this issue Dec 6, 2022 · 6 comments
Closed

TypeScript rewrite #174

RedstoneWizard08 opened this issue Dec 6, 2022 · 6 comments
Labels
on hold 🛑 We will look into it at a later time

Comments

@RedstoneWizard08
Copy link

I'm currently rewriting this in TypeScript, and I will submit a PR when I'm done. I think that a TypeScript rewrite would be a great step in stability and dev-experience, since it would support generics, inheritance, and a bunch more features. (Goodbye, util.inherits()!)

This would solve:

RedstoneWizard08 added a commit to RedstoneWizard08/node-oauth2-server that referenced this issue Dec 7, 2022
@jankapunkt jankapunkt added the on hold 🛑 We will look into it at a later time label Dec 7, 2022
@jankapunkt
Copy link
Member

On hold until we have discussed this.

@lohart13
Copy link

Is this something that is still being considered?

As a sub part of the migration to typescript, have you considered changing to use ECMAScript modules (esm)?
CommonJS (cjs) can still be supported by using a transpiler such as babel or webpack, and if migrated to typescript, this can be down with the typescript package as part of the build process.

@jankapunkt
Copy link
Member

Hi @lohart13 we definitely consider Typescript in the long run. Regarding esm, I'm not sure if it's beneficial, since it's one more rewrite and I would like to avoid a hard dependency to a specific bundler.

@lohart13
Copy link

Ok, I have recently written a similar version of oauth2-server in typescript for another project, do you want me to submit this as a PR?

Out of interest, would this be in scope for v5 or a future release?

@jankapunkt
Copy link
Member

@lohart13 thanks but we currently have a pending PR for a TS rewrite but it's blocked since at least I still have not enough typescript skills to do a sufficient review. However, this is definitely on my agenda as it's required for another project, too.

Maybe you could take a look into the pending TS rewrite PR and leave some comments.

@jorenvandeweyer
Copy link
Member

A TypeScript rewrite is definitely on the roadmap. This would be in the scope of v5 since we are converting a lot of stuff to ES6+ see #212

We'll be accepting PR's after v5 has been published. Closing for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
on hold 🛑 We will look into it at a later time
Projects
None yet
Development

No branches or pull requests

4 participants