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

Type definition #9

Merged
merged 4 commits into from
Jun 27, 2017
Merged

Conversation

brunokrebs
Copy link
Contributor

Adding Typescript type definition.

@brunokrebs
Copy link
Contributor Author

No no no, apparently not working. Closing till I figure it out the correct way.

@brunokrebs brunokrebs closed this Apr 17, 2017
@brunokrebs brunokrebs reopened this Apr 17, 2017
@brunokrebs
Copy link
Contributor Author

Not that hard! @types/express-jwt dependency was in the wrong place.

"dependencies": {
"@types/express-jwt": "0.0.34",
Copy link
Member

Choose a reason for hiding this comment

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

Why not in devDependencies?

Copy link
Contributor Author

@brunokrebs brunokrebs Apr 18, 2017

Choose a reason for hiding this comment

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

DevDependencies of dependencies are not installed along. That is, if I have a TypeScript project that has jwks-rsa as a dependency, @types/express-jwt will not get installed if it is defined as a devDependency instead of as a denpendency. Then the project won't compile and the developer will have to manually install @types/express-jwt.

My first attempt was to configure it as a devDependency, but it didn't work. Also, the publishing page on the TypeScript documentation states that the developer has to:

Make sure all the declaration packages you depend on are marked appropriately in the "dependencies" section in your package.json.

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