4
4
4dinterface2014-11-02 14:17:28
npm
4dinterface, 2014-11-02 14:17:28

How to use npm packages written in typescript in typescript?

There is an application written in typescript
There is a package in node_modules and it is also written in typescript
The package has a dependency and this is also a package written in typescript
How to connect packages written in typescript from a typescript application that are in node_modules without specifying the full path.
I would like to see the following picture
import Experement=require("package name/lib/filename")
now I have to write something like
import Experement=require("../../node_modules/package name/lib/filename" )

Answer the question

In order to leave comments, you need to log in

1 answer(s)
N
Nikolai Kupstas, 2015-05-20
@Illorian

I would suggest using browserify, in which case you would just write require('jquery') and that's it.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question