ndeet / plg_system_less

A Joomla! system plugin to compile .less files on the fly.
GNU Lesser General Public License v3.0
17 stars 13 forks source link

Joomla and less.js 1.4+ #12

Closed piotr-cz closed 10 years ago

piotr-cz commented 11 years ago

There's a new version of less.js available.

However 1.4 introduced some breaking changes (like changes in string interpolation) that produce errors when used together Bootstrap 2.1.0 (this version is shipped with Joomla 3.0 - 3.1).

So leaving this as a warning note, at least until there's new Joomla release with Bootstrap 2.3.2.

Less.js 1.3.1+ should be safe to use with all Bootstrap versions.

Example of less.js 1.4 + Bootstrap 2.1.0:

ParseError: Unrecognised input
in mixins.less on line 552, column 7:

551    .spanX (@index) when (@index > 0) {
552      (~".span@{index}") { .span(@index); }
553      .spanX(@index - 1);

To test upload to media/plg_less/js/ a less-[version].js file, plugin will use up the latest version.

ndeet commented 11 years ago

Good point, also lessphp is not yet compatible with less.js 1.4. See https://github.com/leafo/lessphp/issues/426

We may stick with 1.3.1+ compatibility for now.

gavinerickson commented 11 years ago

I just installed less following the commands on their website, and have the issue outlined here when i try to recompile joomla's bootstrap files.

Any tips on how to uninstall and install the 1.3.1 version you mention here? On OSX 10.8 if thats relevant. [edit] actually it was fairly easy to uninstall: sudo npm -g rm less

and the install: sudo npm -g install less@1.3.1

Thanks for having the reference to the error msg here - i wouldn't have know what to fix otherwise.

ndeet commented 10 years ago

Fixed in master thanks to @robwent release will follow in the next days.