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 support! #281

Merged
merged 13 commits into from
Apr 29, 2019
Merged

Typescript support! #281

merged 13 commits into from
Apr 29, 2019

Conversation

nwalters512
Copy link
Contributor

@nwalters512 nwalters512 commented Apr 22, 2019

Following up on #220. This PR by no means converts fully to TypeScript, but it does add it to our toolchain so that we can incrementally add types in the future. The build process is a little wonky given that Next doesn't support transpiling server files itself (see vercel/next.js#1735) so we have to work around that. I'm going to write docs explaining what I did and why I did it so that if problems come up in the future, future maintainers have something to go off of.

TODO

  • Document the build process

@vercel
Copy link

vercel bot commented Apr 22, 2019

This pull request is automatically deployed with Now.
To access deployments, click Details below or on the icon next to each push.

Copy link
Member

@james9909 james9909 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks like a pretty good base to start with. Don't forget the changelog entry!

package.json Outdated Show resolved Hide resolved
src/util/index.ts Show resolved Hide resolved
@nwalters512
Copy link
Contributor Author

Did my best to add a suitable linting config for TypeScript - there's a bit of weird duplication of some rules between JS and TS and I had to add some overrides since there's not great built-in support for dual-language projects in typescript-eslint. Lmk how things look to you!

Copy link
Member

@james9909 james9909 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, we can clean up the ESLint config whenever we fully convert to TypeScript.

@nwalters512 nwalters512 merged commit 775bc1c into master Apr 29, 2019
@nwalters512 nwalters512 deleted the typescript branch April 29, 2019 19:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants