manuelvanrijn / bootstrap-switch-rails

A small gem for putting bootstrap-switch into the Rails asset pipeline
MIT License
58 stars 18 forks source link

.css to .css.scss: easier to import in a sass file & update update_from_... #5

Closed umhan35 closed 11 years ago

umhan35 commented 11 years ago

Since .css file can't be imported in a .scss file, I changed bootstrap-switch.css to bootstrap-switch.css.scss file. Instruction is included in README.md

update_from_vendor.sh is also updated so we don't need to clone the git repo.

manuelvanrijn commented 11 years ago

Thanks for your pull request.

First of I'm not going to merge this just yet before you can clarify the following points to me :smile:

  1. Sure wget is a solution, but you need to have it installed. If you are for example on windows, this won't work
  2. Why do you need to use the @import? If you are integrating it in the asset pipeline you could just type:
/*
*= require bootstrap-switch
*/

Please let me know

ghost commented 11 years ago

First one is that, I was thinking git clone takes long time to run and wget will be faster. You are right that wget will be a new dependency, but people on windows don't usually install git command line neither and they will just install Github gui client or an Eclipse plugin instead. From this point of view, using wget might win over git.

The second one. I want some customization for the css file and with current .css file it won't work when using import "bootstrap-switch" in a SASS file. By changing the extension to .css.scss, you can import the css file and put the switch stuff in one file so I don't have 2 files loaded on my dev machine. I can also using @extend and othe SASS feature too after that.

I know the current code simply works and my changes are optional, but this pull will offer a better way and more flexibility.

Cheers

manuelvanrijn commented 11 years ago

alright I'v picked a few commits from your pull request. I haven't changed the way i update the vendor libraries because I do use the git command line from my windows system.

Anway the scss change is merged into the master branch

Regards