How can we use Bootstrap mixin?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

How can we use Bootstrap mixin?

stepharo
Hi

I read that it is not really good to use
tbsContainer: and friend in seaside bootstrap and I would like to know

     - what are bootstrap mixin tags?
     - how do we use them?

Stef

Reply | Threaded
Open this post in threaded view
|

Re: How can we use Bootstrap mixin?

Stephan Eggermont-3
On 16-03-16 09:08, stepharo wrote:
> I read that it is not really good to use tbsContainer: and friend in > seaside bootstrap and I would like to know > > - what are bootstrap
mixin tags? - how do we use them

The nice thing about all the tbsXXX methods is that they support mixing
ordinary Seaside canvas and Bootstrap specific code, and make very clear
when you are using what.
What I don't like about all the tbsXXX methods is that they provide a
(nearly) full duplication of the canvas vocabulary, and don't make it
easy to switch from standard Seaside to Bootstrap. That can be achieved
by adding a subclass of the canvas that generates bootstrap specific
html, and making sure that is used.

Stephan



Reply | Threaded
Open this post in threaded view
|

Re: How can we use Bootstrap mixin?

Damien Cassou-2
In reply to this post by stepharo
stepharo <[hidden email]> writes:

> Hi
>
> I read that it is not really good to use
> tbsContainer: and friend in seaside bootstrap and I would like to know
>
>      - what are bootstrap mixin tags?
>      - how do we use them?

everything is explained here: Please stop embedding Bootstrap classes in
your HTML!
http://ruby.bvision.com/blog/please-stop-embedding-bootstrap-classes-in-your-html


The argument is that having html code like this:

    <div class="row">
      <div class="span6">...</div>
      <div class="span6">...</div>
    </div>

goes against the separation of rendering and content that CSS is
supposed to bring. Adding all those bootstrap classes everywhere in the
HTML is not better than adding <table> tags to layout web pages.

In the above web page, the author explains how to use SCSS/SASS/Less
mixins to add sanity to your html. Something like:

    <div class="book-previews">
      <div class="book-preview">...</div>
      <div class="book-preview">...</div>
    </div>

and the SCSS/SASS/Less stylesheet:

    .book-previews {
      .makeRow();        // Mixin provided by Bootstrap
      ...
    }



--
Damien Cassou
http://damiencassou.seasidehosting.st

"Success is the ability to go from one failure to another without
losing enthusiasm." --Winston Churchill

Reply | Threaded
Open this post in threaded view
|

Re: How can we use Bootstrap mixin?

Stephan Eggermont-3
On 16-03-16 11:05, Damien Cassou wrote:
> everything is explained here: Please stop embedding Bootstrap classes  > in your HTML!

Ah yes. The problem is somewhat less acute in Seaside because we take
care of the reuse on the smalltalk side, so this is all generated code.
And from a practical point of view: css does not bring separation of
rendering and content. It might try to, but it doesn't succeed. It is
too verbose and isn't powerful enough.

Stephan



Reply | Threaded
Open this post in threaded view
|

Re: How can we use Bootstrap mixin?

Damien Cassou-2
Stephan Eggermont <[hidden email]> writes:

> On 16-03-16 11:05, Damien Cassou wrote:
> Ah yes. The problem is somewhat less acute in Seaside because we take
> care of the reuse on the smalltalk side, so this is all generated code.
> And from a practical point of view: css does not bring separation of
> rendering and content. It might try to, but it doesn't succeed. It is
> too verbose and isn't powerful enough.

agree, that's why alternatives such as Less and SASS are popular.

--
Damien Cassou
http://damiencassou.seasidehosting.st

"Success is the ability to go from one failure to another without
losing enthusiasm." --Winston Churchill

Reply | Threaded
Open this post in threaded view
|

Re: How can we use Bootstrap mixin?

Sven Van Caekenberghe-2
And there is even a CSS tool in Pharo to augment CSS like Less & SASS, I forgot the name ...

> On 16 Mar 2016, at 11:41, Damien Cassou <[hidden email]> wrote:
>
> Stephan Eggermont <[hidden email]> writes:
>
>> On 16-03-16 11:05, Damien Cassou wrote:
>> Ah yes. The problem is somewhat less acute in Seaside because we take
>> care of the reuse on the smalltalk side, so this is all generated code.
>> And from a practical point of view: css does not bring separation of
>> rendering and content. It might try to, but it doesn't succeed. It is
>> too verbose and isn't powerful enough.
>
> agree, that's why alternatives such as Less and SASS are popular.
>
> --
> Damien Cassou
> http://damiencassou.seasidehosting.st
>
> "Success is the ability to go from one failure to another without
> losing enthusiasm." --Winston Churchill
>


Reply | Threaded
Open this post in threaded view
|

Re: How can we use Bootstrap mixin?

CyrilFerlicot


On 16/03/2016 11:45, Sven Van Caekenberghe wrote:
> And there is even a CSS tool in Pharo to augment CSS like Less & SASS, I forgot the name ...
>
>

RenoirST?

https://ci.inria.fr/pharo-contribution/view/Books/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/RenoirST/RenoirST.html

--
Cyril Ferlicot

http://www.synectique.eu

165 Avenue Bretagne
Lille 59000 France


signature.asc (817 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: How can we use Bootstrap mixin?

Sven Van Caekenberghe-2

> On 16 Mar 2016, at 12:06, Cyril Ferlicot Delbecque <[hidden email]> wrote:
>
>
>
> On 16/03/2016 11:45, Sven Van Caekenberghe wrote:
>> And there is even a CSS tool in Pharo to augment CSS like Less & SASS, I forgot the name ...
>>
>>
>
> RenoirST?
>
> https://ci.inria.fr/pharo-contribution/view/Books/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/RenoirST/RenoirST.html

Yes, I think so ;-)

> --
> Cyril Ferlicot
>
> http://www.synectique.eu
>
> 165 Avenue Bretagne
> Lille 59000 France
>