koajs / koa

Expressive middleware for node.js using ES2017 async functions

Home Page:https://koajs.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

TS2503 [ERROR]: Cannot find namespace 'accepts'.

idranme opened this issue · comments

TS2503 [ERROR]: Cannot find namespace 'accepts'.
accept: accepts.Accepts;
~~~~~~~
at https://cdn.esm.sh/v66/@types/koa@2.13.4/index.d.ts:729:17

It would be better to export koa types from this repo like fastify... @miwnwski @niftylettuce!!

@idanran whoever wrote those typings needs to fix them, they're not officially supported by any maintainer in this repo so there's nothing I can do about this.

@3imed-jaberi This question has been brought up and shut down multiple times. There are no plans to add TS typings to the repo AFAIK.

@miwnwski, I would like to share an honest opinion about Koa... I liked a lot everything in this framework from the onion architecture, dealing with the concurrency (async-await, no callback hell), all used design patterns, the quality of the project structure, and much more features ...

Unfortunately, I see that Koa.js isn't enough active and this affects the marketing and the consumers (companies) who trust the maintenance more than the framework itself. For that, alternatives like Fastify and Express are used nowadays more than Koa!

And I believe that happen because the core maintainers who have read and write access to the repositories don't available in the last 2 years and personally, I tried as much as possible to keep this framework and grow through my contribution not only on the core module 'koa' also on the middlewares and you can check almost repositories and sure you will find my PRs! Also, I have tried many times to contact @niftylettuce @dead-horse @jonathanong ...etc to add me as a maintainer to be able to add/modify/review/publish modules but no reply except @niftylettuce who tell me that he didn't have access to add new maintainers ...!

I see that we have a lot of work here on Koa, like updating the Official documentation and related website, rewriting the framework with TypeScript, rewriting the core middlewares with TypeScript, providing one recommended way to do things like body parsers, providing official adapters to integrate plugins/middlewares coming from other frameworks like Fastify and Express, minify the core module size as much as we can such @nfantone when he says that on mime dependency, providing some layers to respect the DRY principles, add official boilerplate or maybe CLI tool ...etc and should listen to all community suggestion and look to it!

In the event that the project continues to be neglected and the lack of response continues, I find myself obliged to abandon the project and go to help more active projects by contributing and maintaining such as Express, Fastify ...etc

And I would like to thank @mcollina to maintain Fastify and @dougwilson for Express 🙏. Really it's phenomenal work during the last years!

@3imed-jaberi We just sent you an invite to the Koa organization koajs on GitHub. If you need specific publishing access please let us know by pinging @titanism. We will review your publish requests on a manual basis until we're confident and trusted. Please ensure you have 2FA added on GH and npm. For publishing we use np.

While as a team we don't support TypeScript, we're open to you adding types and other related needs for that community.

We are confident in Koa and have built a huge underlying framework at https://github.com/ladjs which also powers our email service at https://forwardemail.net, which it itself is open-source and all Koa-based, blazing fast (it even has its own Redis-based request caching), and is fairly feature packed (it has not only web server, but a proxy, API, and job scheduler too). I think that the core internals of Koa router could be rewritten, but Koa itself is solid so far - please let us know if there's anything in particular that's something core-related that needs looked at, e.g. security or a bug.

for router take a look at https://github.com/Cweili/koa-router-find-my-way no issue so far