larvitcss

0.7.119 • Public • Published

Build Status

larvitcss

Compile, minify, autoprefix etc css from a folder. This module is designed to remove the need to precomile css.

Uncompiled files, like .scss, .sass, .less, .stylus etc overrides precompiled .css files with a conflicting name.

The callback is always called, and req.finished is set to true when no file is found.

Installation

npm i larvitcss;

Usage

For usage as middleware in for instance Express or larvitbase:

const larvitcss = require('larvitcss');
const { Log } = require('larvitutils');
const express = require('express');
const app = express();

app.use(larvitcss({
	log: new Log(), // Optional
	basePath: 'my_path/public', // Optional, defaults to "public/" under current process path,
	notFoundController: (req, res) => { // Optional, controller for file not found, default to setting 404 status code.
		res.statusCode = 404;
		res.end('File not found from special controller');
	},
}));
const larvitcss = require('larvitcss');
const { Log } = require('larvitutils');
const LBase = require('larvitbase');
const lBase = new LBase({middlewares: [larvitcss()]});

Development mode

Set environment variable LARVITCSS_NO_CACHE to disable cache

Changelog

0.6.0

  • Removed larvitfs functionality. basePath is not specified instead and larvitcss is used as a middleware.

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
0.3.100.3-latest
0.7.11959latest

Version History

VersionDownloads (Last 7 Days)Published
0.7.11959
0.7.1180
0.7.1170
0.7.1160
0.7.1150
0.7.1130
0.7.1120
0.7.1110
0.7.1100
0.7.1090
0.7.1080
0.7.1070
0.7.1060
0.7.1050
0.7.1040
0.7.1030
0.7.1020
0.7.1010
0.7.1000
0.7.990
0.7.980
0.7.970
0.7.960
0.7.950
0.7.940
0.7.930
0.7.920
0.7.910
0.7.900
0.7.890
0.7.880
0.7.870
0.7.860
0.7.850
0.7.840
0.7.830
0.7.820
0.7.810
0.7.800
0.7.790
0.7.780
0.7.770
0.7.760
0.7.750
0.7.740
0.7.730
0.7.720
0.7.710
0.7.700
0.7.690
0.7.680
0.7.670
0.7.660
0.7.650
0.7.640
0.7.630
0.7.620
0.7.610
0.7.600
0.7.590
0.7.581
0.7.570
0.7.560
0.7.550
0.7.540
0.7.530
0.7.520
0.7.510
0.7.500
0.7.490
0.7.480
0.7.470
0.7.460
0.7.450
0.7.440
0.7.430
0.7.420
0.7.410
0.7.400
0.7.390
0.7.380
0.7.370
0.7.360
0.7.350
0.7.340
0.7.330
0.7.320
0.7.310
0.7.300
0.7.290
0.7.280
0.7.271
0.7.260
0.7.250
0.7.240
0.7.230
0.7.220
0.7.210
0.7.200
0.7.190
0.7.180
0.7.170
0.7.160
0.7.150
0.7.140
0.7.130
0.7.120
0.7.110
0.7.100
0.7.90
0.7.80
0.7.70
0.7.60
0.7.50
0.7.40
0.7.30
0.7.20
0.7.10
0.7.00
0.6.30
0.6.20
0.6.10
0.6.00
0.5.70
0.5.60
0.5.50
0.3.10
0.5.40
0.5.20
0.5.10
0.5.00
0.4.10
0.4.00
0.3.00
0.2.40
0.2.20
0.2.00
0.1.20
0.1.10
0.1.00

Package Sidebar

Install

npm i larvitcss

Weekly Downloads

61

Version

0.7.119

License

MIT

Unpacked Size

6.7 kB

Total Files

5

Last publish

Collaborators

  • vktr
  • lilleman
  • gagge
  • klabbekluck
  • jaggu-snorr
  • jaggu-darull
  • jaggu-larvit-npm-publish