3.1.2 • Published 4 years ago

simpl3s v3.1.2

Weekly downloads
12
License
MIT
Repository
github
Last release
4 years ago

Simpl3s

Small, fast, quick and easy node.js file flinger with a silly name.

Features

  • Small static file HTTP server
  • Fast!
  • CSS/HTML/JS files are automatically minified and gzipped
  • JSON/SVG/TXT/XML file are automatically gzipped
  • Silly name

Quick usage

require('simpl3s').standAloneServer();

Sample configuration

const simpl3s = require('simpl3s'),
    config = {
        gzip    : true,
        minify  : true,
        port    : 8081,
        path    : './public'
    };

simpl3s.standAloneServer(config);

Complete configuration

const simpl3s = require('simpl3s'),
    config = {
        etag        : true,
        gzip        : true,
        immutable   : true,
        maxAge      : 181635468200,
        minify      : true,
        path        : './www',
        port        : 8080
    };

simpl3s.standAloneServer(config);

Serve a single file

const simpl3s = require('simpl3s'),
    server = require('http'); 

server
    .createServer(simpl3s.serveFile)
    .listen(8080);

Just optimise static assets

require('simpl3s').speedify({}, './public');

Notes

Explicit port configuration will be ignored if a cloud environment is detected. Defaults to 8080 when no port is specified.

Installation

npm

  • npm install simpl3s
3.1.2

4 years ago

3.1.1

4 years ago

3.1.0

4 years ago

3.0.24

4 years ago

3.0.23

4 years ago

3.0.22

5 years ago

3.0.21

5 years ago

3.0.20

5 years ago

3.0.13

5 years ago

3.0.12

5 years ago

3.0.11

5 years ago

3.0.1

5 years ago

3.0.0

5 years ago

2.1.98

5 years ago

2.1.97

5 years ago

2.1.96

6 years ago

2.1.95

6 years ago

2.1.94

6 years ago

2.1.93

6 years ago

2.1.92

6 years ago

2.1.91

7 years ago

2.1.9

7 years ago

2.1.8

7 years ago

2.1.7

7 years ago

2.1.5

7 years ago

2.1.3

7 years ago

2.1.2

7 years ago

2.1.1

8 years ago

2.1.0

8 years ago

2.0.6

8 years ago

2.0.5

8 years ago

2.0.4

8 years ago

2.0.3

8 years ago

2.0.0

8 years ago

1.0.0

9 years ago

0.4.3

9 years ago

0.4.2

9 years ago

0.4.1

9 years ago

0.4.0

9 years ago

0.3.9

9 years ago

0.3.8

9 years ago

0.3.7

9 years ago

0.3.6

9 years ago

0.3.5

9 years ago

0.3.4

9 years ago

0.3.3

9 years ago

0.3.2

9 years ago

0.3.1

9 years ago

0.3.0

9 years ago

0.2.9

9 years ago

0.2.8

9 years ago

0.2.7

9 years ago

0.2.6

9 years ago

0.2.5

9 years ago

0.2.4

9 years ago

0.2.3

9 years ago

0.2.1

9 years ago

0.2.0

9 years ago