Extension, Plugin

Archived
Forum
(read-only)

Minimee

ExpressionEngine 2

Back to this add-on's main page
View Other Add-ons From John D. Wells

     

CSS minifying and working, but JS minifying but not working

Bug Report

jayhlee
jayhlee

I have the following JS that seems to be minifying, but in so doing, it’s also not working.  Something seems to be breaking in the process. Is there something I’m not doing right?

{exp:minimee:js}
[removed][removed]
[removed][removed]
[removed][removed]
[removed][removed]
[removed][removed]
{
/exp:minimee:js} 
John D Wells
# 1
Developer
John D Wells

Hi jayhlee,

I’m afraid the forum has stripped your example code - would you mind trying again, or using something like pastebin.com?

Also could you describe a bit more about how it isn’t working exactly?  Do you have an example online?

Best,
John

jayhlee
# 2
jayhlee

I think I figured out what the issue is. It seems like I can minimee the CSS within a snippet, but when I try to do the same with JS in a snippet, it doesn’t work.  When I take the same JS mimimee code and just put it directly within my template rather than the snippet, it works.

John D Wells
# 3
Developer
John D Wells

Hi jayhlee,

That sounds a bit strange - snippets should be inserted into your templates before the parsing engine gets to Minimee, so it *shouldn’t* have an effect (as you can see happening with your CSS).  And programatically there’s little difference between processing CSS vs JS tags… Would you mind posting an example of your code?

Cheers,
John

John D Wells
# 4
Developer
John D Wells

(Closing due to no reply; I’m guessing it was a parse order issue to begin with).

- John