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.

Move types from DefinitivelyTyped to here 🙇🏽‍♂️

See original GitHub issue

Summary 💭

We’ve been maintaining the types for this library on DefinitivelyTyped. It’s been working ok so far as there was no interest in moving the source code to TS to get the types automatically generated.

However, it’s challenging 🧯 to keep the types up to date, given they live in a separate repository and rely on updates from contributors. After speaking with @balazsorban44, we think we can spike to move the types to a folder here (types/), get them linted through dtslint and integrated with the build pipeline 🎊

Tasks ✅

  • Move types to this repo, to a folder called types in the root (suggestions welcome)
  • Add dtslint and add a command to lint the types
    • add it to the CI
  • Modify package.json to declare types for the package
  • Modify build script to get types into /dist (suggestions welcome)
  • Make a beta release and verify everything works correctly
  • Update the README and website to explain types are now part of the next-auth package
  • Test whether the new types take precedence over @types/next-auth
  • fix typos
  • Sort-out module augmentation issues
  • Deprecate @types/next-auth
  • Release new types on next-auth

Additional context 📓

@JuanM04 @euxn23, you’ve been actively maintaining the types in DefitnivelyTyped. Would you be interested in joining/supporting this effort? (any other contributors welcome 💚)

( cc. @iaincollins )

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:1
  • Comments:12 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
lluiacommented, Apr 4, 2021

@JuanM04 super 💯 , if you make PR and merge on beta, can you then update the ✅ on this issue accordingly? In this way we can keep track on where we’re at in the migration 🙇🏽‍♂️

1reaction
balazsorban44commented, Apr 4, 2021

Added the beta branch https://github.com/nextauthjs/next-auth/tree/beta, it can now be targeted in PRs, and once they are merged, they will automatically be released to the next-auth@beta channel on npm 🤞

Read more comments on GitHub >

github_iconTop Results From Across the Web

Move TypeScript to DefinitelyTyped · Issue #16 - GitHub
I've been playing with the new inferring mechanism in typescript 2.8, but unfortunately it falls short due to not supporting function overloads.
Read more >
Updating Typescript Declaration Files from Definitely Typed
Recently I ran across an issue with an NPM package in my TypeScript project; Property doesn't exist on type of object , the...
Read more >
Typescript Partials
It's as if we'd defined a new copy of the type, but given every property a ?, like name?: string. 🙇‍♂️ If you...
Read more >
Publishing Typings to DefinitelyTyped | by Max Boguslavskiy
DefTyped types and libraries don't contain the @type that you want to add; Existing typings should be updated; The package provides its ...
Read more >
@types/move-concurrently - npm
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/move-concurrently. index.d.ts. // Type definitions ...
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