Standard Framework 11ty Plugin
Complete integration of the Standard Framework CSS system with Eleventy. Includes automatic asset management, enhanced markdown, template filters, backlinks, content encryption, and zero-configuration setup.
Quick Start
1. Install
npm install @zefish/standard
2. Add to eleventy.config.js
import Standard from "@zefish/standard";
export default function (eleventyConfig) {
eleventyConfig.addPlugin(Standard);
return {
dir: { input: "content", output: "_site" }
};
}
3. Use in Templates
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
{% standardAssets %}
</head>
<body>
{{ content | safe }}
</body>
</html>
4. Build
npx @11ty/eleventy
Done! Your 11ty site now has Standard Framework styling.
Whatβs Included
π¨ CSS Framework
- Typography system with golden ratio
- Semantic color system with light/dark themes
- Responsive grid layout system
- Vertical rhythm spacing
- Beautiful components (buttons, forms, cards)
- Complete utility class system
See CSS Framework documentation
π Markdown Enhancements
- Automatic table of contents
- Footnotes
- Obsidian-style callouts
- Code block escaping
- Enhanced syntax highlighting
See Markdown Guide
π§ Template Filters
- String transformations
- Date formatting
- URL manipulation
- Content processing
- Custom helpers
See Filters Guide
π Wiki Features
- Automatic backlinks
- Bidirectional linking
- Reference detection
- Link suggestions
See Backlinks Guide
π Encryption
- Inline content encryption
- Password-protected content
- Client-side decryption
- No server required
See Encryption Guide
π― Shortcodes
{% standardAssets %}β Include CSS and JS{% standardLab %}β Include experimental features- Plus more custom shortcodes
Configuration Options
eleventyConfig.addPlugin(Standard, {
// Directory where CSS/JS files are copied to
outputDir: "assets/standard",
// Copy files from node_modules to output directory
copyFiles: true,
// Use CDN instead of local files (faster for production)
useCDN: false,
// Languages to escape in code blocks
escapeCodeBlocks: []
});
Asset Inclusion
Local Files (Default)
{% standardAssets %}
Outputs:
<link rel="stylesheet" href="/assets/standard/standard.min.css">
<script src="/assets/standard/standard.min.js" type="module"></script>
From CDN
eleventyConfig.addPlugin(Standard, {
useCDN: true
});
Then {% standardAssets %} uses unpkg CDN:
<link href="https://unpkg.com/@zefish/standard" rel="stylesheet">
<script src="https://unpkg.com/@zefish/standard/js" type="module"></script>
Experimental Lab
{% standardLab %}
Includes experimental JavaScript features.
Global Data
Access framework data in templates:
{{ standard.layout.meta }}
Learning Path
Beginner
- Getting Started β Set up and basics
- CSS Framework β Style your content
- Markdown β Write with enhancements
Intermediate
Advanced
- Encryption β Protect content
- Advanced Features β Power user tips
- Performance β Optimization
Common Use Cases
Blog with Standard Styling
---
title: My Blog Post
---
# {{ title }}
Your blog post content with beautiful Standard Framework styling.
Documentation Site
---
eleventyNavigation:
key: Documentation
title: Documentation
---
# Documentation
Automatically get wiki-style backlinks and beautiful typography.
Portfolio
---
---
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4">
<!-- Your portfolio items -->
</div>
Knowledge Base
---
---
# Topic
Your knowledge base entry with automatic backlinks to related pages.
File Structure
Recommended project structure:
my-site/
βββ eleventy.config.js
βββ package.json
βββ content/
β βββ index.md
β ββ posts/
β β ββ post-1.md
β β ββ post-2.md
β ββ docs/
β ββ guide-1.md
β ββ guide-2.md
βββ _includes/
β ββ layouts/
β ββ base.njk
β ββ article.njk
βββ _site/
ββ index.html
ββ posts/
ββ docs/
ββ assets/standard/
ββ standard.min.css
ββ standard.min.js
ββ standard.lab.js
Features by Category
Content Creation
- β Enhanced markdown
- β Automatic table of contents
- β Footnotes
- β Callouts
- β Code highlighting
Styling
- β Complete CSS framework
- β Light/dark themes
- β Responsive layouts
- β Typography scales
- β Components
Functionality
- β Template filters
- β Shortcodes
- β Backlinks
- β Content encryption
- β Global data
Performance
- β Minified CSS/JS
- β CDN option
- β Small file sizes (14KB CSS, 2KB JS gzipped)
- β Minimal dependencies
Comparison with Similar Tools
| Feature | Standard | Eleventy | Jekyll |
|---|---|---|---|
| CSS Framework | β Included | β Not included | β Minimal |
| Markdown Enhancement | β Full | β οΈ Limited | β οΈ Limited |
| Backlinks | β Automatic | β No | β No |
| Dark Mode | β Built-in | β No | β No |
| Encryption | β Included | β No | β No |
| Performance | β Excellent | β Excellent | β Good |
API Reference
- Standard Framework Plugin β Auto-generated API
- Markdown Plugin β Markdown enhancements
- Filter Plugin β Template filters
- Shortcode Plugin β Custom shortcodes
- Backlinks Plugin β Wiki features
- Encryption Plugin β Content encryption
Getting Help
- π Documentation β Comprehensive guides
- π Report Issues
- π¬ Discussions
- β Star on GitHub
Next Steps
Ready to build? Start here:
- Getting Started β Installation and setup
- CSS Framework β Learn the styling system
- Markdown β Master markdown features
- Filters β Transform your content
- Backlinks β Connect your pages
Version 0.10.52 | Eleventy | MIT License