Open wynksaiddestroy opened 8 years ago
Thanks for asking. Yes, I would love this addition! To accept the pull request, I'd like to see support for both Bootstrap 3 and 4 with a way for users to choose. Keep an eye on backward-compatibility (I don't think this enhancement should make us bump tabulous to version 3).
As for tests, I sincerely and deeply apologize for the difficulty in running them and setting them up, since they are targeting various versions of Ruby and Rails and it's hard to install and test all of that stuff locally. Instructions are here https://github.com/techiferous/tabulous/blob/master/CONTRIBUTING.md and here https://github.com/techiferous/tabulous/blob/master/spec/applications/README.md
When I first set up tabulous, the custom of using Travis CI for testing a gem with various versions of Ruby and Rails was still getting established. I couldn't figure out how to set it up to test something complex like tabulous, which isn't just an isolated piece of Ruby or Rails functionality but is an engine that involves integrating views, controllers, its tabulous.rb config file and even front-end libraries like Bootstrap. I needed some way to support good automated test coverage as well as a way to preview it running in the browser to make sure that bootstrap integration (and tabulous' default CSS) was working.
Anyway, that's why the tests can take quite a lot of effort to set up and run locally. I hope you are up for this effort. If not, you can lean on me by taking the tests as far as you can and I can pick up from there. Note that I don't have a lot of free time for open source projects nowadays so my turn-around time will likely be slow and my bandwidth limited. But if you are currently working with Bootstrap 4 alpha, maybe we can have tabulous support good to go and released by the time Bootstrap 4 gets more stable.
Thank you for your interest in tabulous and in contributing to make it better!
Thanks for asking. Yes, I would love this addition! To accept the pull request, I'd like to see support for both Bootstrap 3 and 4 with a way for users to choose. Keep an eye on backward-compatibility (I don't think this enhancement should make us bump tabulous to version 3).
Backward compatibility isn't an issue at all. I created three new renderers (bootstrap4_navbar_renderer.rb, bootstrap4_pill_renderer.rb and bootstrap4_renderer.rb) and didn't touch the existing Bootstrap 3 renderers at all.
So if you want to use the "new" Bootstrap 4 renderers you put renderer :bootstrap4_navbar
in your tabulous.rb instead of renderer :bootstrap_navbar
which still utilizes Bootstrap 3.
Anyway, that's why the tests can take quite a lot of effort to set up and run locally. I hope you are up for this effort. If not, you can lean on me by taking the tests as far as you can and I can pick up from there. Note that I don't have a lot of free time for open source projects nowadays so my turn-around time will likely be slow and my bandwidth limited.
I'll try my best to get the test suite up und running. If I run in any problems, I'll leave you a note.
But if you are currently working with Bootstrap 4 alpha, maybe we can have tabulous support good to go and released by the time Bootstrap 4 gets more stable.
Although there's still much development on the new Bootstrap version, I think there won't be any major changes to the basic structure of the CSS classes and HTML elements. So I hope that we can have Bootstrap 4 support in the near future 😊
I hope I don't miss something, but do the test applications in spec/applications/bootstrap/
have actually any tests?
No, no automated tests. You'd want to generate a suite of Rails apps similar to these: https://github.com/techiferous/tabulous/tree/master/spec/applications/bootstrap Then just fire up the Rails apps and manually test to see if anything looks wonky.
Although version 4 of Bootstrap is still declared as alpha I'm already using it in one of my applications. To be able to use Bootstrap 4 along with tabulous I took the Bootstrap 3 renderers and edited them in ways that they comply with Bootstrap 4. The renderers are fairly complete. But I still haven't wrote any tests. Before I'm going to do that, I wanted to ask whether you would appreciate the support of Bootstrap 4 in tabulous.