# npm-less

> Fix LESS to import a la node require algorithm

Latest version **1.0.0** (published 2014-09-30) · 0 weekly downloads

## Install

```sh
npm install npm-less
pnpm add npm-less
yarn add npm-less
bun add npm-less
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2014-09-30 |
| First published | 2013-05-25 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 4 |
| Known vulnerabilities | 0 (+2 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 9 |
| Author | Raynos |
| Maintainers | raynos |

## Links

- npm: https://www.npmjs.com/package/npm-less
- Repository: https://github.com/Raynos/npm-less
- Issues: https://github.com/Raynos/npm-less/issues
- npm.io page: https://npm.io/package/npm-less

## Dependencies (4)

- [less](https://npm.io/package/less.md) ~1.7.4
- [request](https://npm.io/package/request.md) ~2.39.0
- [resolve](https://npm.io/package/resolve.md) ~0.7.4
- [compiled-files](https://npm.io/package/compiled-files.md) ~0.1.1

## Recent versions

- 1.0.0 (latest) — 2014-09-30
- 0.5.0 — 2014-07-30
- 0.4.0 — 2014-07-13
- 0.3.2 — 2014-01-30
- 0.3.1 — 2013-11-23
- 0.2.2 — 2013-06-13
- 0.2.1 — 2013-06-13
- 0.1.2 — 2013-05-25

## README

# npm-less

<!-- [![build status][1]][2] [![dependency status][3]][4]

[![browser support][5]][6]
 -->
Fix LESS to import a la node require algorithm

## Example

```js
var http = require("http")
var path = require("path")
// Simple http router
var Router = require("routes-router")
// Simple static file server
var ecstatic = require("ecstatic")

var ServeLess = require("npm-less/serve")

var router = Router()

// ServeLess(rootFolder) returns a http handler
// to server less files. The suggestion is to
// serve /less/foo as /styles/foo/index.js or
// /less/bar as /styles/bar.js
router.addRoute("/less/:appName",
    ServeLess(path.join(__dirname, "styles")))
// static server to serve html page for example
router.addRoute("/", ecstatic({
    root: path.join(__dirname, "static"),
    autoIndex: true
}))

var server = http.createServer(router)

server.listen(9024, function () {
    console.log("demo server listening on port 9024")
})

```

## Installation

`npm install npm-less`

## Contributors

 - Raynos

## MIT Licenced

  [1]: https://secure.travis-ci.org/Raynos/npm-less.png
  [2]: https://travis-ci.org/Raynos/npm-less
  [3]: https://david-dm.org/Raynos/npm-less.png
  [4]: https://david-dm.org/Raynos/npm-less
  [5]: https://ci.testling.com/Raynos/npm-less.png
  [6]: https://ci.testling.com/Raynos/npm-less

---
_Source: https://npm.io/package/npm-less · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
