It would be awesome if someone ported this to Dancer: http://boilerplate-tudorconstantin.dotcloud.com https://github.com/tudorconstantin/Mojolicious-Boilerplate -Naveed
On 07/02/2012 07:18 PM, Naveed Massjouni wrote:
It would be awesome if someone ported this to Dancer:
http://boilerplate-tudorconstantin.dotcloud.com https://github.com/tudorconstantin/Mojolicious-Boilerplate
I think this is pretty similar: http://cowbell.cancan.cshl.edu/ But if there are any useful/cool features that they have and we don't, I can add them. <shameless plug> Note that their template has "bootstrap" hard-coded in the git repository - so to update bootstrap *after* you instantiated their template, you'd have to do it manually (assuming you can't pull from their repository any more, because you've started your own git repository with the real project). While my template allows you to update to the latest bootstrap version with one easy script, without harming anything (and also saves the previous version, just in case). Also, Their template has the mis-feature of using just one CSS in the main layout (bootstrap.css), so for a real project with custom CSS settings, you'll have to either: 1. Create a new custom CSS (easy, but more manual work - so their template could be improved) 2. update "bootstrap.css" directly (not recommended, because then you can't easily upgrade bootstrap) 3. Change the CSS inlined in the layout files - bad form. My template already contains "./public/style.css" (empty by default) that is included after bootstrap.css and overrides it - so if you add your own CSS statement and then upgrade bootstrap - it just works out of the box. Also(2), My template has "font-awesome" integrated (overriding Bootstrap's glyphicons) and easily upgradable, which is way cooler :) </shameless plug> -gordon
On Mon, Jul 2, 2012 at 8:11 PM, Assaf Gordon <gordon@cshl.edu> wrote:
On 07/02/2012 07:18 PM, Naveed Massjouni wrote:
It would be awesome if someone ported this to Dancer:
http://boilerplate-tudorconstantin.dotcloud.com https://github.com/tudorconstantin/Mojolicious-Boilerplate
I think this is pretty similar: http://cowbell.cancan.cshl.edu/
But if there are any useful/cool features that they have and we don't, I can add them.
<shameless plug> Note that their template has "bootstrap" hard-coded in the git repository - so to update bootstrap *after* you instantiated their template, you'd have to do it manually (assuming you can't pull from their repository any more, because you've started your own git repository with the real project).
While my template allows you to update to the latest bootstrap version with one easy script, without harming anything (and also saves the previous version, just in case).
Also, Their template has the mis-feature of using just one CSS in the main layout (bootstrap.css), so for a real project with custom CSS settings, you'll have to either: 1. Create a new custom CSS (easy, but more manual work - so their template could be improved) 2. update "bootstrap.css" directly (not recommended, because then you can't easily upgrade bootstrap) 3. Change the CSS inlined in the layout files - bad form.
My template already contains "./public/style.css" (empty by default) that is included after bootstrap.css and overrides it - so if you add your own CSS statement and then upgrade bootstrap - it just works out of the box.
Also(2), My template has "font-awesome" integrated (overriding Bootstrap's glyphicons) and easily upgradable, which is way cooler :)
</shameless plug>
-gordon
I am pleased to see that your Dancer version is architected better as you note above. That's what I have come to expect from the Dancer community :) However, there are a few things in the mojo version that I think we could really benefit from. For example, the navigation bar at the top with the login/logout/signup stuff. I end up needing that for almost every app I build. Also, notice that they have a built in photo slide show and gallery. That would be really neat to have, but maybe not as important. I will move this conversation to github [https://github.com/agordon/dancer_bootstrap_fontawesome_template] so we can track these feature requests better and so maybe I can contribute instead of just complaining :) -Naveed
On 07/02/2012 10:28 PM, Naveed Massjouni wrote:
However, there are a few things in the mojo version that I think we could really benefit from.
For example, the navigation bar at the top with the login/logout/signup stuff. I end up needing that for almost every app I build. Also, notice that they have a built in photo slide show and gallery. That would be really neat to have, but maybe not as important.
I guess this is a trade-off between having a lean&mean template, that's easy to start working with and doesn't have any bloat, or a full-blown examples of many bootstrap/dancer interactions (like nav-bar, forms, etc.). I do like they idea of having many *working* examples of bootstrap + dancer, where one can just copy&paste them and have it working (bootstrap, IMHO, is notorious with bad examples - and even the mojo website doesn't have it working properly :) ). On the other hand, I'd like to keep the template small and clean, so that a user wouldn't have to start "cleaning up crapware" in the PM file when he/she starts a new Dancer app. Perhaps we could put working examples (and add more and more) in a different PM file? and so the base template would be lean, but we'll have working examples in a separate file... I think I could manage something tonight, I'll push it and we'll go from there. To be continued... -gordon
On 07/02/2012 10:56 PM, Assaf Gordon wrote:
I guess this is a trade-off between having a lean&mean template, that's easy to start working with and doesn't have any bloat, or a full-blown examples of many bootstrap/dancer interactions (like nav-bar, forms, etc.).
I do like they idea of having many *working* examples of bootstrap + dancer, where one can just copy&paste them and have it working (bootstrap, IMHO, is notorious with bad examples - and even the mojo website doesn't have it working properly :) ).
Here's a first shot at it (available in https://github.com/agordon/dancer_bootstrap_fontawesome_template), and usable here: http://cowbell.cancan.cshl.edu/dispatch.cgi/simple_form . Everytime we have another good working example of Dancer+bootstrap, we can simply add the Dancer code in ./lib/examples and the templates in ./views/examples . I would prefer to keep the examples focused - each module demonstrates one thing (e.g. navbar + login) - so that it'll be easy for a user who wants to use one component to find just the relevant code. -gordon
I just wanna say, ++ to the both of you for this discussion and what it is producing. On Tue, Jul 3, 2012 at 7:10 AM, Assaf Gordon <gordon@cshl.edu> wrote:
On 07/02/2012 10:56 PM, Assaf Gordon wrote:
I guess this is a trade-off between having a lean&mean template, that's easy to start working with and doesn't have any bloat, or a full-blown examples of many bootstrap/dancer interactions (like nav-bar, forms, etc.).
I do like they idea of having many *working* examples of bootstrap + dancer, where one can just copy&paste them and have it working (bootstrap, IMHO, is notorious with bad examples - and even the mojo website doesn't have it working properly :) ).
Here's a first shot at it (available in https://github.com/agordon/** dancer_bootstrap_fontawesome_**template<https://github.com/agordon/dancer_bootstrap_fontawesome_template>), and usable here: http://cowbell.cancan.cshl.**edu/dispatch.cgi/simple_form<http://cowbell.cancan.cshl.edu/dispatch.cgi/simple_form>.
Everytime we have another good working example of Dancer+bootstrap, we can simply add the Dancer code in ./lib/examples and the templates in ./views/examples .
I would prefer to keep the examples focused - each module demonstrates one thing (e.g. navbar + login) - so that it'll be easy for a user who wants to use one component to find just the relevant code.
-gordon ______________________________**_________________ Dancer-users mailing list Dancer-users@perldancer.org http://www.backup-manager.org/**cgi-bin/listinfo/dancer-users<http://www.backup-manager.org/cgi-bin/listinfo/dancer-users>
sawyer x wrote, On 07/03/2012 03:14 AM:
I just wanna say, ++ to the both of you for this discussion and what it is producing.
Thanks! One more working example: Tabs/Pills navigation: http://cowbell.cancan.cshl.edu/dispatch.cgi/tabs code available in github: https://github.com/agordon/dancer_bootstrap_fontawesome_template If someone wants to add a new example, there's now an example template in "./lib/examples/example_stub.pm" and "./views/examples/example_stub.tt". -gordon
participants (3)
-
Assaf Gordon -
Naveed Massjouni -
sawyer x