Skip to content

Cant include underscore 3rth party library #1083

@VledicFranco

Description

@VledicFranco

I'm following the 3rth party library installation guide but for underscore, I basically do that same but instead of every 'moment' I replace it with 'underscore', just had to install the typings with typings install dt~underscore --global --save, but the compiler wont find underscore.

The Broccoli Plugin: [BroccoliTypeScriptCompiler] failed with:
Error: Typescript found the following errors:
  /home/franco/Repositories/freyja-estore/tmp/broccoli_type_script_compiler-input_base_path-LIIKQ8Cj.tmp/0/src/app/freyja-api/basket-api.ts (6, 20): Cannot find module 'underscore'.
    at BroccoliTypeScriptCompiler._doIncrementalBuild (/home/franco/Repositories/freyja-estore/node_modules/angular-cli/lib/broccoli/broccoli-typescript.js:115:19)
    at BroccoliTypeScriptCompiler.build (/home/franco/Repositories/freyja-estore/node_modules/angular-cli/lib/broccoli/broccoli-typescript.js:43:10)
    at /home/franco/Repositories/freyja-estore/node_modules/angular-cli/node_modules/broccoli-caching-writer/index.js:152:21
    at lib$rsvp$$internal$$tryCatch (/home/franco/Repositories/freyja-estore/node_modules/angular-cli/node_modules/broccoli-caching-writer/node_modules/rsvp/dist/rsvp.js:1036:16)
    at lib$rsvp$$internal$$invokeCallback (/home/franco/Repositories/freyja-estore/node_modules/angular-cli/node_modules/broccoli-caching-writer/node_modules/rsvp/dist/rsvp.js:1048:17)
    at lib$rsvp$$internal$$publish (/home/franco/Repositories/freyja-estore/node_modules/angular-cli/node_modules/broccoli-caching-writer/node_modules/rsvp/dist/rsvp.js:1019:11)
    at lib$rsvp$asap$$flush (/home/franco/Repositories/freyja-estore/node_modules/angular-cli/node_modules/broccoli-caching-writer/node_modules/rsvp/dist/rsvp.js:1198:9)
    at nextTickCallbackWith0Args (node.js:420:9)
    at process._tickCallback (node.js:349:13)

Moment seems to work fine though

My ng --version:

angular-cli: 1.0.0-beta.5
node: 4.4.4
os: linux x64

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions