jameskleeh / angular-confirm

Confirmation modal dialog for AngularJS
Apache License 2.0
150 stars 75 forks source link

Missing angular-confirm.min.js by installing via npm #74

Closed LionFat closed 8 years ago

LionFat commented 8 years ago

Hi, James. You developed this wonderful module, thank you so much, dude. But we are confused by some strange things: 1) there's a line in package.json:

"main": "angular-confirm.min.js"

2) but! in .gitignore you specified same file - angular-confirm.min.js

By installing this module via npm we have a problem: module does not contain angular-confirm.min.js because of .npmignore which totaly matches with .gitignore. Could you please update the package in npm providing an appropriate .npmignore (which wouldn't contain angular-confirm.min.js).

We've got this error because of missing angular-confirm.min.js:

Module not found: Error: Cannot resolve module 'angular-confirm'
simison commented 8 years ago

Hmm, main shouldn't be pointing to minified version.

jameskleeh commented 8 years ago

@simison Can you point me to some documentation somewhere saying the main file should not be minified?

simison commented 8 years ago

@jameskleeh good question! It's kinda just common knowledge and now that I looked into it I didn't see any mention of this at package.json's spec (but it's designed for backend stuff in mind anyway).

The problem is that if you use minified versions in development, it's quite hard to debug stuff when something breaks. Everyone should be able to minify their JS for production the way that suits them best anyway.

That's how it's also recommended to be with Bower files (#49). Would be logical to get the same file regardless the package manager, anyway.

LionFat commented 8 years ago

@jameskleeh could you please publish last changes on npm or increment version. you know better