jless

A Java implementation of the LESS CSS framework

License

License

GroupId

GroupId

com.github.jryans.jless
ArtifactId

ArtifactId

jless
Last Version

Last Version

0.4.11
Release Date

Release Date

Type

Type

jar
Description

Description

jless
A Java implementation of the LESS CSS framework
Project URL

Project URL

https://github.com/jryans/jless
Project Organization

Project Organization

Bazaarvoice
Source Code Management

Source Code Management

https://github.com/jryans/jless

Download jless

How to add to project

<!-- https://jarcasting.com/artifacts/com.github.jryans.jless/jless/ -->
<dependency>
    <groupId>com.github.jryans.jless</groupId>
    <artifactId>jless</artifactId>
    <version>0.4.11</version>
</dependency>
// https://jarcasting.com/artifacts/com.github.jryans.jless/jless/
implementation 'com.github.jryans.jless:jless:0.4.11'
// https://jarcasting.com/artifacts/com.github.jryans.jless/jless/
implementation ("com.github.jryans.jless:jless:0.4.11")
'com.github.jryans.jless:jless:jar:0.4.11'
<dependency org="com.github.jryans.jless" name="jless" rev="0.4.11">
  <artifact name="jless" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.github.jryans.jless', module='jless', version='0.4.11')
)
libraryDependencies += "com.github.jryans.jless" % "jless" % "0.4.11"
[com.github.jryans.jless/jless "0.4.11"]

Dependencies

compile (4)

Group / Artifact Type Version
org.parboiled : parboiled-java jar 1.0.1
com.google.guava : guava jar r09
commons-lang : commons-lang jar 2.4
commons-io : commons-io jar 1.4

test (2)

Group / Artifact Type Version
org.testng : testng jar 6.1.1
com.googlecode.java-diff-utils : diffutils jar 1.2.1

Project Modules

There are no modules declared in this project.

JLESS

JLESS is a pure Java port of Alexis Sellier's LESS abstraction for CSS, which was written in Ruby. By using only Java to produce the CSS output, this library offers much faster LESS processing for your Java web application when compared with other approaches that wrap interpreters around the original Ruby or JavaScript source.

Quick Start

JLESS can be used either as a command line tool during your build process, or it can be used at runtime to translate LESS content on demand.

git clone git://github.com/jryans/jless.git
cd jless
mvn package

Standalone Tool

# Use -c if you'd like to minify the output
java -jar target/jless-<version>-jar-with-dependencies.jar [-c] <input less file>

Runtime Library

LessProcessor processor = new LessProcessor();
processor.setCompressionEnabled(true); // Minification is off by default
String css = processor.process(<input stream>).toString();

Features

At this time, not all of the features of the LESS language have been ported over:

  • Supported
    • Variables
    • Mixins
    • Mixin Arguments
    • Nesting
  • Unsupported
    • Math Operations
    • Accessors
    • Imports

Support

Please file issues for any problems you encounter.

Credits

Related Projects

  • LESS: The original LESS abstraction in Ruby
  • less.js: A newer implementation in JavaScript
  • lesscss-engine: Wraps less.js with a JavaScript interpreter for use in Java applications

Versions

Version
0.4.11
0.4.10
0.4.9