0

ng2-sweetalert2

ng2-fontawesome

i want to add this to my angular2 cli project what i must add in my angular-cli-build.js

vendorNpmFiles: [
   ..................
   'ng2-bootstrap/**/*.js', <--- for example
    ....................
  ]

my system-config.ts

const map:any ={
     ..................
   'ng2-bootstrap': 'vendor/ng2-bootstrap',
    ....................

}
const packages: any = {
  'ng2-bootstrap': {
    format: 'cjs',
    defaultExtension: 'js',
    main: 'ng2-bootstrap.js'

  }

};
Rommy
  • 447
  • 3
  • 10
  • 23

1 Answers1

-1

The repo wiki has the answer to this: https://github.com/angular/angular-cli/wiki/3rd-party-libs

lbrahim
  • 3,710
  • 12
  • 57
  • 95
  • is that the same? cause in that link just how to import js, not css – Rommy Jun 23 '16 at 09:57
  • @Rommy Your css should be external to the CLI. You can write some gulp task to concatenate and output the file into your dist folder. See more [here](http://stackoverflow.com/a/37981280/1565402) – lbrahim Jun 23 '16 at 10:07