Skip to content
This repository was archived by the owner on Jan 26, 2019. It is now read-only.

Import untranspiled files from module #131

Closed
vincaslt opened this issue Aug 4, 2017 · 1 comment
Closed

Import untranspiled files from module #131

vincaslt opened this issue Aug 4, 2017 · 1 comment

Comments

@vincaslt
Copy link

vincaslt commented Aug 4, 2017

Is there a way to import untranspiled files from node_modules? I see this line under webpack config: "Make sure your source files are compiled, as they will not be processed in any way.", but if I eject, is there a way to make it transpile the imported files along with the project? Basically I want to have commonly shared files package, which I use accross other typescript applications, but linked via package.json. Basically what happens now, is webpack tries to import the files form node modules as javascript files, and breaks on typescript syntax.

@wmonk
Copy link
Owner

wmonk commented Aug 4, 2017

No this is not possible unless you eject. I would not recommend this approach either. I would recommend distributing packages as javascript. You can supplement with typings to take advantage of TS.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants