Jump to content

Thinking different: SASS use in themes


yesdev

Recommended Posts

Whilst the move towards SASS is a welcome step for 1.6, there are perhaps better ways of managing SASS than being dependent on Compass. There are ways of removing the Ruby/Compass dependency for Prestashop 1.6 & still maintaining code credibility. This is due to Ruby/Compass creating an overhead that may not be needed.

 

As Prestashop is PHP based, you can actually use PHP to build & compile your SASS styles on the fly:

https://github.com/reyhoun/sass-watcher

 

PHP compilation is slow however in comparison to server level compilation using Apache/C.

 

There is the ability for Apache to manage SASS for your themes (both admin & frontend) on the fly:

https://github.com/sensational/sassphp

 

using the Libsass C++ library. I maintain a custom fork of this latter codebase (also located on Github) and use it to build SASS on the fly for our design team.

 

If your site is hosted using Nginx or Litespeed, there isn't a Nginx / Litespeed equivalent to the Apache extension, though hopefully someone will work on delivering that.

 

So if you want to use SASS without Compass, it's entirely achievable.

Link to comment
Share on other sites

×
×
  • Create New...