You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by Julien NICOLAS <ju...@nereide.fr> on 2018/08/27 08:47:37 UTC

Gradle, Less, Css : Transpile and minify

Hi,

I would like to optimize css and less management using gradle.
I saw that some gradle plugins exists for transpilation (or 
compilation...) less to css and minify and gzip css files.

What do you think if I try to set it in trunk ? I saw that a minifier 
was already implemented in the past but was also removed. Is there any 
technical reasons to remove minifier ?

Let me know your opinions,

Regards,

Julien.

Re: Gradle, Less, Css : Transpile and minify

Posted by Jacques Le Roux <ja...@les7arts.com>.
Le 27/08/2018 à 12:02, Mathieu Lirzin a écrit :
> Hello Julien,
>
> Julien NICOLAS <ju...@nereide.fr> writes:
>
>> I would like to optimize css and less management using gradle.
>> I saw that some gradle plugins exists for transpilation (or
>> compilation...) less to css and minify and gzip css files.
>>
>> What do you think if I try to set it in trunk ? I saw that a minifier
>> was already implemented in the past but was also removed. Is there any
>> technical reasons to remove minifier ?
> I think it is a good idea.  However if we do that, it will be very
> important to have a convenient way to run OFBiz either in development
> mode (without minification) and in production mode (with minification)
> to ease the Javascript debugging.  Since this is a very common
> requirement, I guess those Gradle plugins already provide such facility
> or describe how to customize the impacted tasks.
>
> Thanks.
>
That's indeed a good idea Mathieu

Jacques


Re: Gradle, Less, Css : Transpile and minify

Posted by Julien NICOLAS <ju...@nereide.fr>.
Yes, I can elaborate a better explanation. I would like to be sure that 
there is no historical mistake with the minified files before digging 
further.

I'll open a Jira and make an example to explain my proposal.

Regards,

Julien.


Le 27/08/2018 à 15:00, Taher Alkhateeb a écrit :
> Can you elaborate on how you want to design this feature? Are you
> going to minify the existing file or generate a new one. If you
> generate a new one how will you update the screens to refer to the
> minified version? Some elaboration on the design might help to make a
> better decision here perhaps?
> On Mon, Aug 27, 2018 at 3:20 PM Julien NICOLAS
> <ju...@nereide.fr> wrote:
>> Yes ! This is exactly what I have in mind ;)
>>
>> Using this feature in production using Gulp, It's a pain when you have
>> to debbug in minified version.
>>
>> Julien.
>>
>>
>> Le 27/08/2018 à 12:02, Mathieu Lirzin a écrit :
>>> Hello Julien,
>>>
>>> Julien NICOLAS <ju...@nereide.fr> writes:
>>>
>>>> I would like to optimize css and less management using gradle.
>>>> I saw that some gradle plugins exists for transpilation (or
>>>> compilation...) less to css and minify and gzip css files.
>>>>
>>>> What do you think if I try to set it in trunk ? I saw that a minifier
>>>> was already implemented in the past but was also removed. Is there any
>>>> technical reasons to remove minifier ?
>>> I think it is a good idea.  However if we do that, it will be very
>>> important to have a convenient way to run OFBiz either in development
>>> mode (without minification) and in production mode (with minification)
>>> to ease the Javascript debugging.  Since this is a very common
>>> requirement, I guess those Gradle plugins already provide such facility
>>> or describe how to customize the impacted tasks.
>>>
>>> Thanks.
>>>


Re: Gradle, Less, Css : Transpile and minify

Posted by Taher Alkhateeb <sl...@gmail.com>.
Can you elaborate on how you want to design this feature? Are you
going to minify the existing file or generate a new one. If you
generate a new one how will you update the screens to refer to the
minified version? Some elaboration on the design might help to make a
better decision here perhaps?
On Mon, Aug 27, 2018 at 3:20 PM Julien NICOLAS
<ju...@nereide.fr> wrote:
>
> Yes ! This is exactly what I have in mind ;)
>
> Using this feature in production using Gulp, It's a pain when you have
> to debbug in minified version.
>
> Julien.
>
>
> Le 27/08/2018 à 12:02, Mathieu Lirzin a écrit :
> > Hello Julien,
> >
> > Julien NICOLAS <ju...@nereide.fr> writes:
> >
> >> I would like to optimize css and less management using gradle.
> >> I saw that some gradle plugins exists for transpilation (or
> >> compilation...) less to css and minify and gzip css files.
> >>
> >> What do you think if I try to set it in trunk ? I saw that a minifier
> >> was already implemented in the past but was also removed. Is there any
> >> technical reasons to remove minifier ?
> > I think it is a good idea.  However if we do that, it will be very
> > important to have a convenient way to run OFBiz either in development
> > mode (without minification) and in production mode (with minification)
> > to ease the Javascript debugging.  Since this is a very common
> > requirement, I guess those Gradle plugins already provide such facility
> > or describe how to customize the impacted tasks.
> >
> > Thanks.
> >
>

Re: Gradle, Less, Css : Transpile and minify

Posted by Julien NICOLAS <ju...@nereide.fr>.
Yes ! This is exactly what I have in mind ;)

Using this feature in production using Gulp, It's a pain when you have 
to debbug in minified version.

Julien.


Le 27/08/2018 à 12:02, Mathieu Lirzin a écrit :
> Hello Julien,
>
> Julien NICOLAS <ju...@nereide.fr> writes:
>
>> I would like to optimize css and less management using gradle.
>> I saw that some gradle plugins exists for transpilation (or
>> compilation...) less to css and minify and gzip css files.
>>
>> What do you think if I try to set it in trunk ? I saw that a minifier
>> was already implemented in the past but was also removed. Is there any
>> technical reasons to remove minifier ?
> I think it is a good idea.  However if we do that, it will be very
> important to have a convenient way to run OFBiz either in development
> mode (without minification) and in production mode (with minification)
> to ease the Javascript debugging.  Since this is a very common
> requirement, I guess those Gradle plugins already provide such facility
> or describe how to customize the impacted tasks.
>
> Thanks.
>


Re: Gradle, Less, Css : Transpile and minify

Posted by Mathieu Lirzin <ma...@nereide.fr>.
Hello Julien,

Julien NICOLAS <ju...@nereide.fr> writes:

> I would like to optimize css and less management using gradle.
> I saw that some gradle plugins exists for transpilation (or
> compilation...) less to css and minify and gzip css files.
>
> What do you think if I try to set it in trunk ? I saw that a minifier
> was already implemented in the past but was also removed. Is there any
> technical reasons to remove minifier ?

I think it is a good idea.  However if we do that, it will be very
important to have a convenient way to run OFBiz either in development
mode (without minification) and in production mode (with minification)
to ease the Javascript debugging.  Since this is a very common
requirement, I guess those Gradle plugins already provide such facility
or describe how to customize the impacted tasks.

Thanks.

-- 
Mathieu Lirzin
GPG: F2A3 8D7E EB2B 6640 5761  070D 0ADE E100 9460 4D37

Re: Gradle, Less, Css : Transpile and minify

Posted by Deepak Dixit <de...@hotwax.co>.
Hi Nicolas,

I think we were using yuicompressor, It was conflicting with BIRT reporting
tool.

Here are the reference ticket

https://issues.apache.org/jira/browse/OFBIZ-4849
https://issues.apache.org/jira/browse/OFBIZ-5070

I like the idea to have minified js/css files.
You can create a ticket for the same.

Thanks & Regards
--
Deepak Dixit


On Mon, Aug 27, 2018 at 2:17 PM, Julien NICOLAS <ju...@nereide.fr>
wrote:

> Hi,
>
> I would like to optimize css and less management using gradle.
> I saw that some gradle plugins exists for transpilation (or
> compilation...) less to css and minify and gzip css files.
>
> What do you think if I try to set it in trunk ? I saw that a minifier was
> already implemented in the past but was also removed. Is there any
> technical reasons to remove minifier ?
>
> Let me know your opinions,
>
> Regards,
>
> Julien.
>