Web host does not support .less file extension

advertisements

I am using lesscss.org's styles on my MVC application.

It works great, but unfortunately my web host does not support .less file extensions, neither will they add support.

Seeing though LessCSS makes use of JavaScript, surely there must be a way to rename my CSS file from site.less to site.css and change the JavaScript to make use of the .css extension instead of the .less extension.

Please note I am not using dotLess, and compiling prior to release is also not what I am looking for.


Finally got it working.

All i had to do is modify my web.config of my MVC web application and add the following:

<system.webServer>
  ...
  <staticContent>
    <mimeMap fileExtension=".less" mimeType="text/css" />
  </staticContent>
</system.webServer>

I re-published the site to my hosting provider afrihost, and it wall worked perfectly.