https://github.com/peterszarvas94/lytepage
lytepage - generate static site with go, markdown and templ
https://github.com/peterszarvas94/lytepage
go golang mardown templ
Last synced: about 2 months ago
JSON representation
lytepage - generate static site with go, markdown and templ
- Host: GitHub
- URL: https://github.com/peterszarvas94/lytepage
- Owner: peterszarvas94
- Created: 2024-08-03T11:52:20.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2025-05-29T14:20:43.000Z (about 1 year ago)
- Last Synced: 2025-07-20T01:14:42.754Z (12 months ago)
- Topics: go, golang, mardown, templ
- Language: CSS
- Homepage: https://lytepage.peterszarvas.hu
- Size: 26.9 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# lytepage
## 1. Install
```shell
go install github.com/peterszarvas94/lytepage@latest
```
## 1. Initialize a new project
```shell
lytepage init my-app
```
## 2. Write content
`content/hello/world.md`
```txt
---
title: "Amazing article"
---
## Hello world
How awesome this site is!
Learn:
- go
- templ
```
## 3. Write template
```js
templ PostPage(post *fileutils.FileData) {
{ post.Matter.Title }
@fileutils.HtmlString(post.Html)
}
```
## 4. Generate (for static hosting)
```shell
make gen
```
The generated `public/hello/world/index.html`:
```html
Amazing article
Hello world!
How awesome this site is!
Learn:
- go
- templ
```
## 5. Run locally
SSR mode:
```shell
make ssr
```
Static mode:
```shell
make static
```
Now `localhost:8080/hello/world` is serving your content
Dev mode - soon!