Gradle, Less, Css : Transpile and minify

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

Gradle, Less, Css : Transpile and minify

Julien NICOLAS
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.
Reply | Threaded
Open this post in threaded view
|

Re: Gradle, Less, Css : Transpile and minify

Deepak Dixit-4
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 <[hidden email]>
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.
>
Reply | Threaded
Open this post in threaded view
|

Re: Gradle, Less, Css : Transpile and minify

Mathieu Lirzin
In reply to this post by Julien NICOLAS
Hello Julien,

Julien NICOLAS <[hidden email]> 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
Reply | Threaded
Open this post in threaded view
|

Re: Gradle, Less, Css : Transpile and minify

Jacques Le Roux
Administrator
Le 27/08/2018 à 12:02, Mathieu Lirzin a écrit :

> Hello Julien,
>
> Julien NICOLAS <[hidden email]> 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

Reply | Threaded
Open this post in threaded view
|

Re: Gradle, Less, Css : Transpile and minify

Julien NICOLAS
In reply to this post by Mathieu Lirzin
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 <[hidden email]> 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.
>

Reply | Threaded
Open this post in threaded view
|

Re: Gradle, Less, Css : Transpile and minify

taher
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
<[hidden email]> 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 <[hidden email]> 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.
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: Gradle, Less, Css : Transpile and minify

Julien NICOLAS
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
> <[hidden email]> 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 <[hidden email]> 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.
>>>