zero-configuration web server with built in pre-processing
What is Fedor?
Pre-compilers are becoming extremely powerful and shipping front-ends as static assets has many upsides. It's simple, it's easy to maintain, it's low risk, easy to scale, and requires low cognitive overhead. I wanted a lightweight web server that was powerful enough for me to abandon web frameworks for dead simple front-end publishing.
- easy installation, fast and lightweight
- robust (clean urls, intelligent path redirects)
- built in pre-processing (es6, coffeescript, sass, less, stylue, markdown, browserify additionally)
- first-class layout and partial support
- built in LRU caching in production mode
- can export assets to HTML/CSS/JS
- does not require a build steps or grunt task
- fun to use
|Language Superset||Whitespace Sensitive|
|CSS||LESS, Sass (SCSS)||Stylus, Sass|
sudo npm install -g fedor
Creating a new fedor application is a breeze...
fedor init myproj fedor server myproj
Your Fedor application is now running at http://localhost:3000
Fedor can be used as a library or as a command line utility.
Usage: fedor [command] [options] Commands: init [path] initalize new fedor application (defaults to current directory) server [path] [options] start fedor server compile [path] [options] compile project to static assets multihost [path] [options] start fedor server to host directory of fedor apps Options: -h, --help output usage information -V, --version output the version number
Start the server in root of your application by running...
You may optionally supply a port to listen on...
fedor server --port 8002
Compile an application from the root of your application by running...
You may optionally pass in a path to where you want the compiled assets to go...
fedor compile --output /path/to/cordova/project/www
You may also use fedor as a node library for compiling or running as a server.
Serve up a fedor application...
var fedor =fedor
Or compile fedor application
var fedor =fedor
Or use as Connect/ExpressJS middleware
var express = ;var fedor = ;var app = ;app;app;