angular-ui / bootstrap-bower

This is a bower repository to hold Angular UI Bootstrap releases.
http://angular-ui.github.com/bootstrap/
158 stars 326 forks source link

Fix error in require syntax to make package work in jspm #61

Closed forestjohnsonilm closed 9 years ago

forestjohnsonilm commented 9 years ago

require('./ui-bootstrap-tpls.js') is wrong. it should not have a .js extension.

when I try to load the package in jspm, I am getting a 404 looking for ui-bootstrap-tpls.js.js

Foxandxss commented 9 years ago

Wop, not sure what I put the extension when I don't do that in my other libraries.

It is weird that JSPM will append the extension again.

We hope to release a new version soon as well so this merge will be there.

sectore commented 9 years ago

Any chance to release a hotfix-version 0.13.2. to include this fix?

Foxandxss commented 9 years ago

We will make a new release this weekend with fully angular 1.4 support.

On the other hand, I tried this package with JSPM and works fine for me with the .js.

I just did a:

import uibs from 'angular-ui-bootstrap'
sectore commented 9 years ago

@Foxandxss Great, thanks!

BTW: No way to use the importstatement your have mentioned before. How does your jspm.config.js look? Because I'm wondering about using angular-ui-bootstrap instead of angular-bootstrap.

Foxandxss commented 9 years ago

@sectore You have to use angular-ui-bootstrap not angular-bootstrap.

angular-ui-bootstrap is the only package we support and it works with JSPM out of the box.

sectore commented 9 years ago

@Foxandxss Have you run jspm install angular-bootstrap or jspm install angular-ui-bootstrap to install the package? I got the following error using last one:

jspm install angular-ui-bootstrap --save
    Updating registry cache...
err  Repo jspm:angular-ui-bootstrap not found!
Foxandxss commented 9 years ago

@sectore that error is normal. JSPM has its own repository of packages and we are not there, so you need to do:

jspm install --save npm:angular-ui-bootstrap

sectore commented 9 years ago

@Foxandxss: Got it! Thanks for your help and keep up the great work :metal: