Yii Framework Forum: Extension For Using Less In Yii - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Extension For Using Less In Yii Rate Topic: -----

#1 User is offline   sammousa 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 1
  • Joined: 16-July 13

Posted 16 July 2013 - 06:15 PM

Hey guys,

I created an extension for Yii to support LESS CSS.
While I found a few existing extensions I feel that they did not have the correct approach.

My extension is a behavior that should be attached to CClientScript.
After being attached it can be used to register LESS files just like you would CSS files:

Yii::app()->getClientScript()->registerLessFile($path-to-less-file, $media);

- It includes lessphp (leafo.net) which is used to compile the LESS files to normal CSS.
- CSS files are by default published to [assets]/less/randomfilename.css

At this point there is no support for clientside LESS using less.js, this will be added later.

Posting this in the forum since my forum account is too "new".

And since I can't post links go to github and check the SamMousa/yii-less repository to find out more!
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users