tj/node-prune

Doesn't work with angular-cli generated projects

NelsonBrandao opened this issue · 3 comments

Any project generated by angular-cli fails to build after running node-prune

Steps to reproduce:

  1. Install angular-cli
  2. Run ng new random-project
  3. Navigate inside the newly created project folder
  4. Run yarn
  5. Run node-prune
  6. Run ng serve

It will fail to build the project

Cannot read property 'length' of undefined
TypeError: Cannot read property 'length' of undefined
    at createSourceFile ((...)/node_modules/typescript/lib/typescript.js:14876:109)
(...)

At me all works, at you what version?

It's working for me, but then when I run ng serve I end up with errors which is not really surprising according to the README:

node-prune is a small tool to prune unnecessary files from ./node_modules, such as markdown, typescript source files

How should we be able to work with Typescript without that?

tj commented

It's (currently) meant more for deployments etc