Run LESS in JSFiddle
by barzik
HTML
<script src="http://lesscss.googlecode.com/files/less-1.3.0.min.js"></script>
<div class="somediv ">
Look a box with shadow
</div>
CSS
@some-var: red;
#some-mixin() {
background-color: black;
}
.somediv {
color: @some-var;
#some-mixin();
}
JavaScript
// Step 1: Select the style element and change it to text/less
$('head style[type="text/css"]').attr('type', 'text/less');
// Step 2: Tell LESS to refresh the styles
less.refreshStyles();