Skip to content

Commit 4df0833

Browse files
author
Christian Lizell
committed
Add draft handling in Eleventy configuration and mark AI blog post as draft
1 parent 71bcf38 commit 4df0833

2 files changed

Lines changed: 8 additions & 0 deletions

File tree

_posts/2026-01-25-ai-som-primar-arbetsmetod.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
---
22
title: "AI som primär arbetsmetod"
33
date: 2026-01-25
4+
draft: true
45
description: "Hur Ossy-teamet på SVT Nyheter bygger hela arbetssättet runt AI, med principer, flöde och kvalitet som system."
56
tags:
67
- blogg

eleventy.config.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,13 @@
11
import syntaxHighlight from "@11ty/eleventy-plugin-syntaxhighlight";
22

33
export default function(eleventyConfig) {
4+
// Drafts: exkludera helt vid build, visa vid serve/watch
5+
eleventyConfig.addPreprocessor("drafts", "*", (data) => {
6+
if (data.draft && process.env.ELEVENTY_RUN_MODE === "build") {
7+
return false;
8+
}
9+
});
10+
411
// Syntax highlighting för kodblock
512
eleventyConfig.addPlugin(syntaxHighlight);
613

0 commit comments

Comments
 (0)