add project page for lila and render djot pages

This commit is contained in:
2025-11-14 01:09:33 +01:00
parent 47473a53b5
commit 910038a5e3
5 changed files with 62 additions and 14 deletions

View File

@@ -2,7 +2,7 @@ import lume from "lume/mod.ts";
import nav from "lume/plugins/nav.ts";
import codeHighlight from "lume/plugins/code_highlight.ts";
import googleFonts from "lume/plugins/google_fonts.ts";
import { djotRender } from "./_djot.ts";
import { djotLoader, djotRender } from "./_djot.ts";
const site = lume();
@@ -23,5 +23,6 @@ site.copy("favicon.svg");
site.data("djot", djotRender);
site.filter("djot", djotRender);
site.loadPages([".dj"], djotLoader);
export default site;

View File

@@ -14,7 +14,7 @@ export function djotRender(content: string): string {
return djot.renderHTML(djot.parse(content));
}
export default async function djotLoader(path: string | URL) {
export async function djotLoader(path: string | URL) {
const content = await Deno.readTextFile(path);
const ast = djot.parse(content);

View File

@@ -1,12 +0,0 @@
# Projects
## Lila
A simple programming language. It uses [Cranelift] as a compiler backend.
## Myrtle
A note-taking helper similar to [zk].
[Cranelift]: https://cranelift.dev
[zk]: https://zk-org.github.io/zk

17
projects/index.dj Normal file
View File

@@ -0,0 +1,17 @@
# Projects
## [Lila](./lila.dj)
A simple programming language. It uses [Cranelift][] as a compiler backend.
## Myrtle
A note-taking helper similar to [zk][].
## Statice
A static site generator supporting [Djot][].
[Cranelift]: https://cranelift.dev
[Djot]: https://djot.net
[zk]: https://zk-org.github.io/zk

42
projects/lila.dj Normal file
View File

@@ -0,0 +1,42 @@
# Lila
A simple programming language I make in my free time.
I'm trying to make it modular so I can easily try and compare different backends and tooling.
## Status
For now it can JIT-compile basic programs using [Cranelift][].
I'm still not decided on which language features I want to explore.
## Source mirrors
- [GitHub](https://github.com/rpqt/lila)
- [Gitea](https://git.turifer.dev/rpqt/lila)
- [SourceHut](https://git.sr.ht/~rpqt/lila)
## Roadmap
### Parsing
- [x] Pest parser backend
- [ ] (wip) [Tree-sitter][] parser backend
- [ ] (wip) Tree-sitter grammar -- [git][tree-sitter-lila]
- [ ] (wip) Parser based on the tree-sitter grammar
### Static analysis
- [x] Basic type checking
### Codegen
- [x] (wip) Cranelift JIT compiler
- [x] Basic CLI
- [ ] Run the compiler on Wasm
- [ ] Wasm codegen
- [ ] REPL
[Cranelift]: https://cranelift.dev
[Tree-sitter]: https://tree-sitter.github.io/tree-sitter
[tree-sitter-lila]: https://git.sr.ht/~rpqt/tree-sitter-lila