Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
web
Manage
Activity
Members
Labels
Plan
Issues
63
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Operate
Environments
Terraform modules
Monitor
Incidents
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ecobytes
web
Merge requests
!2
feat(10): add content collections
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
feat(10): add content collections
feat/10/contentCollections
into
feature/8
Overview
0
Commits
7
Pipelines
0
Changes
11
Merged
Jon Richter
requested to merge
feat/10/contentCollections
into
feature/8
2 years ago
Overview
0
Commits
7
Pipelines
0
Changes
11
Expand
Updates Astro to use content collections.
Closes
#10 (closed)
Edited
2 years ago
by
Jon Richter
👍
0
👎
0
Merge request reports
Compare
feature/8
feature/8 (base)
and
latest version
latest version
7ef85fc2
7 commits,
2 years ago
11 files
+
649
−
3410
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
11
Search (e.g. *.vue) (Ctrl+P)
src/components/Global.astro
+
36
−
35
Options
@@ -2,46 +2,47 @@
import "../global.scss";
import { zipper } from "fp-ts-contrib";
import Link from "./Link.astro";
import Toc from "./Toc.astro";
const { languages = zipper.insertLeft("en")(zipper.of("de")) } =
Astro.props as { languages: zipper.Zipper
<string>
};
Astro.props as { languages: zipper.Zipper
<string>
};
---
<html
lang=
{languages.focus}
>
<head>
<meta
charset=
"utf-8"
/>
<link
rel=
"shortcut icon"
type=
"image/vnd.microsoft.icon"
href=
"favicon.ico"
/>
<meta
name=
"viewport"
content=
"width=device-width"
/>
<meta
name=
"generator"
content=
{Astro.generator}
/>
<title>
ecobytes
</title>
</head>
<body>
<header>
<small
style=
"position:relative;"
>
<Link
href=
"/"
><h1>
ecobytes
</h1></Link>
<img
src=
"favicon.ico"
style=
"position:absolute; left:-18px; top:-7px; pointer-events: none;
<head>
<meta
charset=
"utf-8"
/>
<link
rel=
"shortcut icon"
type=
"image/vnd.microsoft.icon"
href=
"favicon.ico"
/>
<meta
name=
"viewport"
content=
"width=device-width"
/>
<meta
name=
"generator"
content=
{Astro.generator}
/>
<title>
ecobytes
</title>
</head>
<body>
<header>
<small
style=
"position:relative;"
>
<Link
href=
"/"
><h1>
ecobytes
</h1></Link>
<img
src=
"favicon.ico"
style=
"position:absolute; left:-18px; top:-7px; pointer-events: none;
width:24px;
filter: drop-shadow(0px 1px 0px #eee) drop-shadow(1px 0px 0px #eee)"
/>
</small>
<small>
{
languages.lefts.map((entry) =>
<button>
{entry}
</button>
)
}
<button
aria-pressed=
"true"
disabled
>
{languages.focus}
</button
>
{languages.rights.map((entry) =>
<button>
{entry}
</button>
)}
</small>
</header>
<main>
<slot><code>
Error on SSG: Missing Global content
</code></slot>
</main>
<footer>
<Link
href=
"Impressum"
>
Impressum
</Link
>
</footer>
</body>
/>
</small>
<small>
{languages.lefts.map((entry) =>
<button>
{entry}
</button>
)}
<button
aria-pressed=
"true"
disabled
>
{languages.focus}
</button
>
{languages.rights.map((entry) =>
<button>
{entry}
</button>
)}
</small>
</header>
<main>
<slot><code>
Error on SSG: Missing
`
Global
`
content
</code></slot>
</main>
<footer>
<Toc
collectionName=
"policies"
/
>
</footer>
</body>
</html>
Loading