sample-mdserver
mdserver
A sample server that renders markdown on the fly, with LiveReload.
Installation
$ git clone git@github.com:bcardiff/sample-mdserver.git
$ shards build
Usage
$ bin/mdserver [dir]
Using data at /full/path/to/dir
Listening on http://127.0.0.1:3000
LiveReload on http://0.0.0.0:35729
Open http://127.0.0.1:3000
.
When the server receives a GET /file
:
- If a
dir/file.md
exists, it will render it withdir/styles.css
and livereload script - Otherwise it will return
dir/file
with aHTTP::StaticFileHandler
When changes in dir
are detected a reload will be sent to the browser.
Contributors
- Brian J. Cardiff - creator and maintainer
Repository
sample-mdserver
Owner
Statistic
- 0
- 0
- 0
- 0
- 3
- about 4 years ago
- October 1, 2020
License
MIT License
Links
Synced at
Sun, 22 Dec 2024 13:49:20 GMT
Languages