1.7 KiB
1.7 KiB
posixlycorrect.com
Personal homepage built with Zola.
Build
zola build(direct)zola serve(local dev server)
Project Structure
content/— Markdown contentblog/— Blog postslib/— Library/reference articlestriforce-strategies/— Triforce Strategies LLC contenttools/— Interactive calculators/tools
templates/shortcodes/— Custom shortcodes (override theme)static/js/— JavaScript filesstatic/css/— CSS filesthemes/tabi-lean/— Theme (git subtree, do not edit directly)config.toml— Site configuration
Content Conventions
- Frontmatter: TOML (
+++delimiters) - Section indices:
_index.md - Internal links:
@/path/to/file.md
Adding Interactive Tools
To add a new tool under triforce-strategies/tools/:
-
Create shortcode:
templates/shortcodes/tool_name.html- HTML structure (form, canvas, results container)
- Load JS via
{{ get_url(path='js/toolName.js') | safe }} - Include
<noscript>fallback
-
Create JS:
static/js/toolName.js- Wrap in IIFE:
(function() { 'use strict'; ... })(); - Use theme CSS variables for colors (--text-color, --primary-color, etc.)
- Scale canvas for retina:
window.devicePixelRatio
- Wrap in IIFE:
-
Create CSS:
static/css/tool-name.css- Use theme CSS variables from
themes/tabi-lean/sass/main.scss - Responsive layout with media queries
- Use theme CSS variables from
-
Create page:
content/triforce-strategies/tools/tool_name.md- Frontmatter:
[extra] stylesheets = ["css/tool-name.css"] - Invoke shortcode:
{{ tool_name() }}
- Frontmatter:
Example: snp500_vs_anything (fund comparison calculator with Monte Carlo simulation)
Commit Style
type: description (e.g., blog: add post title)