1.1 KiB
1.1 KiB
FWDekker Template
The base template for pages on fwdekker.com.
Contains utilities for
- settings up header, footer, and navigation,
- interacting with local storage (and an in-memory variant for testing), and
- form validation.
Simply import template.js
and template.css
to get it working.
All JavaScript functionalities are exposed using the window.fwdekker
object.
Some functionalities are automatically executed after configuring some <meta>
tags in the HTML.
For example, set <meta name="fwd:nav:target" content="#nav" />
to automatically put the navigation bar in the #nav
element.
All meta-tag behaviour is opt-in.
Read the files' individual documentation for more information.
Development
Requirements
Setting up
# Install dependencies (only needed once)
$> npm ci
Building
# Build the tool in `dist/` for development
$> npm run dev
# Same as above, but automatically rerun it whenever files are changed
$> npm run dev:server
# Build the tool in `dist/` for deployment
$> npm run deploy