Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bower install for addons #185

Closed
martindiphoorn opened this issue Mar 7, 2016 · 4 comments
Closed

Bower install for addons #185

martindiphoorn opened this issue Mar 7, 2016 · 4 comments

Comments

@martindiphoorn
Copy link
Contributor

Currently i use the Dexie.Observable an saw that since version 1.3 they are removed from the distribution. So im unable to use 1.3 with bower. Are you planning to add these again?

@dfahlander
Copy link
Collaborator

Apologies for any inconvenience regarding the addons. The addons are published in their own npm packages now. I'll see what I can do to make them installable over bower.

Once i've put a bower.json for both addons, you can use

bower install https://npmcdn.com/dexie-observable/bower.zip

or

bower install https://npmcdn.com/dexie-observable@0.1.x/bower.zip

or

bower install https://npmcdn.com/dexie-observable@0.1.2/bower.zip

But right now, that doesnt work because bower.json is missing.

There are several reasons for not supporting bower for each addon. First reason is that addons are now es6 based and dependant of a build process. Second reason is that I would like addons to be their own packages (even though some addons may be placed in the same repo). And then, it's about the problem that comes with having to commit build output to github. For dexie, I'll keep supporting bower by temporarily checking in build output when releasing, and then deleting it from the repo afterwards. This is all done in a release script so I don't have to think about it.

To sum it up, bower support will be fixed very soon (tonight/tomorrow). I hope it feels ok to install each addon as its own package from the npmcdn.com url and not included in dexie package?

dfahlander added a commit that referenced this issue Mar 8, 2016
@dfahlander
Copy link
Collaborator

I've published dexie-observable 0.1.3 and dexie-syncable 0.1.3 with bower support through npmcdn.com.

bower install https://npmcdn.com/dexie-observable/bower.zip
bower install https://npmcdn.com/dexie-syncable/bower.zip

Please let me know if you are ok with that, and we can close the issue.

@dfahlander
Copy link
Collaborator

I noticed that bower.zip only contains the main file, not min, map, or es6.

How do you bower users react to having the addons installed this way? Please 👍 or 👎 . I could add a script that builds the addons and includes them in the Dexie bower package again if people thinks the current way is too cumbersome. Looks like there are a lot of bower users.

dfahlander added a commit that referenced this issue Mar 17, 2016
Including addons in npm and bower package.json
WIP for improved bower experience of #185
dfahlander added a commit that referenced this issue Mar 17, 2016
Including addons in bower package.json #185.
@dfahlander
Copy link
Collaborator

Ok, so I updated the release script so that the dexie bower package also includes the transpiled addons under addons/Dexie.Observable/dist/dexie-observable.js. Dist dir also includes minified and map files.

Like it was before, just do:

bower install dexie

$ ls -Rla bower_components/dexie/addons/*/dist
bower_components/dexie/addons/Dexie.Observable/dist:
total 144
drwxr-xr-x 1 David 197610     0 Mar 21 13:45 ./
drwxr-xr-x 1 David 197610     0 Mar 21 13:45 ../
-rw-r--r-- 1 David 197610 44529 Mar 21 13:45 dexie-observable.js
-rw-r--r-- 1 David 197610 64087 Mar 21 13:45 dexie-observable.js.map
-rw-r--r-- 1 David 197610 11183 Mar 21 13:45 dexie-observable.min.js
-rw-r--r-- 1 David 197610 14733 Mar 21 13:45 dexie-observable.min.js.map

bower_components/dexie/addons/Dexie.Syncable/dist:
total 188
drwxr-xr-x 1 David 197610     0 Mar 21 13:45 ./
drwxr-xr-x 1 David 197610     0 Mar 21 13:45 ../
-rw-r--r-- 1 David 197610 59860 Mar 21 13:45 dexie-syncable.js
-rw-r--r-- 1 David 197610 85066 Mar 21 13:45 dexie-syncable.js.map
-rw-r--r-- 1 David 197610 12643 Mar 21 13:45 dexie-syncable.min.js
-rw-r--r-- 1 David 197610 18097 Mar 21 13:45 dexie-syncable.min.js.map

David@DavidHPEnvy2 MINGW64 /c/repos/lab2
$

Will continue to support bower for addons by including them in the dexie package.

Those who use npm or jspm will install addons as separate packages. This only applies to bower since it is coupled to the github repo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants