question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Distribute TypeScript types with koa package

See original GitHub issue

It’d be really convenient if the Koa types were distributed with the koa package rather than requiring a separate install of @types/koa.

I see that requests for a TypeScript rewrite have been closed, but could the types at least be pulled in? It might help keep them in sync as well.

Issue Analytics

  • State:open
  • Created 2 years ago
  • Reactions:23
  • Comments:8 (3 by maintainers)

github_iconTop GitHub Comments

23reactions
jimmywartingcommented, Nov 5, 2021

sometimes i don’t get it, vscode is able to follow js and understand jsdoc without having separate type definition files. I most often see this @types as unnecessary

0reactions
jaydensericcommented, Dec 7, 2022

@jimmywarting editor or TypeScript config doesn’t get published or used when the package is installed by users. You don’t just want type safety for the source code of the package you are authoring, but also for your users consuming the published package.

Read more comments on GitHub >

github_iconTop Results From Across the Web

TypeScript with Koa: Part — 2. Type Definitions ... - Medium
To parse request body, we're going to use the koa-bodyparser package which can handle a number of content types for us. If we...
Read more >
@types/koa - npm
Start using @types/koa in your project by running `npm i @types/koa`. ... TypeScript icon, indicating that this package has built-in type ...
Read more >
Documentation - Publishing - TypeScript
Don't combine it with yours, keep each in their own file. · Don't copy the declarations in your package either. · Do depend...
Read more >
How to publish Deno modules to NPM
If you aren't familiar with oak, it is a koa inspired HTTP ... Writes out the package as a set of ESM, CommonJS...
Read more >
Using Docker for local TypeScript development - Inviqa
npm install -D typescript @types/koa ... First, we'll add a couple of scripts to our package.json to make things a little simpler.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found