esvit / ng-table

Simple table with sorting and filtering on AngularJS
http://esvit.github.io/ng-table
BSD 3-Clause "New" or "Revised" License
2.77k stars 851 forks source link

Issues Figuring Out What Version Works for Angular 1.5 and Including/Building Package #944

Open mtpultz opened 7 years ago

mtpultz commented 7 years ago

I'm able to use v1.0.0 using bower and have been using it in our current application for awhile, but I'd like to update to 2.2.0 or 3.x if that's possible. I'm not sure what versions of AngularJS these versions support. The docs don't mention it, but the examples at least indicate Angular 1.4.x works with ngTable 2.0.2, but after that I can't seem to find any other documentation?

I tried using the unpkg script provided in the docs, but when used it doesn't recognize module, looks to be loading an index.ts file, and I'd rather include this in our build if possible like our other vendors. Is this possible?

I'm also still writing in es5 for Angular 1.5.x and using wiredep to pull in the dist into my index, but I'm not sure how the build the package since npm run build:full throws missing script build:full, and I don't want to have each dev have to run this manually each time an install or update is made. Is there a way to do this automatically since the dist isn't provided by the package?

ccrowhurstram commented 7 years ago

Q: Which version number is supported?

According to the package.json - 1.2 or above.

Q: Why can't I use the latest UMD script published at unpkg by adding it as script tag to my page - it fails when I try because it doesn't recognize module

Not sure what's going on here as all the examples online are using the UMD script published at unpkg -they seem to be working fine.

The only thing to note is that depending on the link you use to unpkg, you might be getting a redirect (302). Take for example the links below:

Can you reproduce the problem in a codepen (or jsbin or jsfiddle, or plunker)? The simplest way to get going is to fork an existing codepen mentioned in the project README.md

Q: How do I build the package since the npm script build:full is missing

Not sure why this is failing for you. The latest version (as of writing this reply), does include this script (see here)