shlomiassaf / ngx-modialog

Modal / Dialog for Angular
http://shlomiassaf.github.io/ngx-modialog
MIT License
686 stars 242 forks source link

issues referencing the modules #294

Open squarewave24 opened 7 years ago

squarewave24 commented 7 years ago

im trying to add this into my existing app, and having issues while following your directions

in systemjs.config

  'angular2-modal': 'node_modules/angular2-modal' // this will give me a 404 

this works:

  'angular2-modal': 'node_modules/angular2-modal/bundles/angular2-modal.umd.js',

the issue is later, when I try to also reference the bootstrap module

  'angular2-modal': 'node_modules/angular2-modal/bundles/angular2-modal.umd.js',
  'angular2-modal/plugins/bootstrap': 'node_modules/angular2-modal/plugins/bootstrap/bootstrap.js',

later in my module, this compiles:

import { ModalModule } from 'angular2-modal';
import { BootstrapModalModule } from 'angular2-modal/plugins/bootstrap';

but i am getting a 404 on BootstrapModalModule because it's still looking in the first location

http://localhost:3000/node_modules/angular2-modal/plugins/bootstrap/bootstrap.js

squarewave24 commented 7 years ago

If i go by your example,

import { ModalModule } from 'angular2-modal';
import { BootstrapModalModule } from 'angular2-modal/plugins/bootstrap';

It looks good in VS Code, but at runtime I get this error,

zone.js:1382 GET http://localhost:3000/node_modules/angular2-modal/plugins/bootstrap.js 404 (Not Found)

zone.js:1382 GET http://localhost:3000/node_modules/angular2-modal/ 404 (Not Found)

it appears to be looking in 1 directory up.

my systemjs.config:

'angular2-modal': 'node_modules/angular2-modal',

i can tweak it to work for one, but not both..

squarewave24 commented 7 years ago

anyone?

wlievens commented 7 years ago

Does anyone have a working SystemJS config for the renamed/restructured ngx-modialog?