Answer the question
In order to leave comments, you need to log in
How to make an NPM module in Typescript for Node.js?
How to make an NPM module in Typescript for Node.js?
Interested in the stages of creation.
Is there any way to get around without compiling the module to publish to NPM?
To clarify: I need to build a module that will be used in another TS module.
I did the following:
package.json
{
"name": "express-typescript",
"main": "index.ts",
"typings": "index.d.ts",
...
}
export * from './src/Server';
export declare module 'express-typescript' {
export * from 'index';
}
Cannot find module 'express-typescript'.
Answer the question
In order to leave comments, you need to log in
It is possible without compilation, only those who also use TS can use it.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question