Skip to content

Quick Start

Write your first LOVE-LANG program in under 5 minutes.

Let’s get you writing LOVE-LANG code in the next few minutes.


Every LOVE-LANG program begins with a base statement — a key/value pair that defines a name and assigns it a value.

hello.love
# The simplest LOVE programme
name = "Hello, World!"
version = 1
description = "My first LOVE programme"

LOVE uses = or the keyword is as its assignment operator. Both are equivalent:

assignment.love
greeting = "Hello"
farewell is "Goodbye"

  1. Install LOVE-LANG

    Clone the repository and build from source:

    Terminal window
    git clone https://github.com/love-metalang/love-lang
    cd love-lang
    gleam build
  2. Write your first programme

    Create a file called hello.love:

    hello.love
    @Import[Prelude::*]
    name = "LOVE-LANG"
    version = 0.0.1
    author = "you"
    license = "MIT"
    description = "The List Oriented Virtualized Evaluator"
  3. Run it

    Terminal window
    love run hello.love

LOVE treats everything as typed lists. An L1 expression wraps values in single brackets:

lists.love
colours = [red green blue]
numbers = [1 2 3 4 5]
mixed = ["hello" 42 :keyword]

Double brackets denote operations — applying a function to arguments:

math.love
result = [[ + 1 2 ]] # 3
squared = [[ * result result ]] # 9

LOVE has a rich type system. Annotate any key with @[Type] or :Type:

typed.love
name @[String] = "Alice"
age :Number = 30
active @[Boolean] = true
tags @[List] = [developer lisp love]

Use @Import to load modules from the standard library:

imports.love
@Import[Prelude::*]
@Import[Invariants::DependencyInjection]
@Import[Stdlib::Math]
result = [[ Math.sqrt 144 ]]

Here is a real LOVE programme from the examples directory — a static site generator bootstrap:

ssg.love
@Import[Prelude::*]
@Import[Invariants::DependencyInjection]
@DependencyInjection
[#mode Automatic]
init = [#! [args :List[String]] ]
@DependencyInjection
[#mode Automatic ::alias[AutomaticMode]]
init = [#! [args :List[String]]
@and[>]
result :List = args
-> @apply[self]
-> @create[List <- args]
-> @filter[@and[True]] ]

Language Reference

Explore the full syntax specification, including all five bracket levels.

Read Reference →

Compiler Pipeline

Understand the OPERA → MATERIALIZE → SIMULATE compilation workflow.

Read Guide →