Build
Templates
Start an App from a dashboard, list, detail or finance template, or add a blank Function or Query, then run it locally and publish it.
limilake add writes the starting files for an App, a Function or a Query
into your Workspace checkout. Apps come in five templates, from a blank page
to a finance dashboard with eight Queries. Functions and Queries have one
blank starting point each.
add only writes files on your machine. Nothing reaches LimiLake until you
commit and push to main.
Before you startLink to this section
You need the CLI, a signed-in profile and a clone of your Workspace. See Setup and access.
limilake workspace clone finance
cd financeA Workspace created on LimiLake already has its root files. Run
limilake workspace init only in a checkout that has no limilake.toml, for
example a new, empty Git repository. It writes five files and nothing else:
limilake.toml
package.json
pnpm-lock.yaml
pyproject.toml
uv.lockEvery add command and workspace init takes --dry-run. It prints the
files the command would create or update and writes nothing:
limilake add app sales --template dashboard --dry-runAdd an App from a templateLink to this section
-
Pick a slug (lowercase letters, digits and inner hyphens) and a template:
bashlimilake add app sales --template dashboardWithout
--templateyou getblank. The App goes toapps/sales/. The first App in a Workspace also updates the rootpackage.jsonandpnpm-lock.yaml. A template with Queries writes them toqueries/, and the command writes the App's typed client toapps/sales/src/generated/limilake.ts. -
Read the
Next:lines the command prints. The first one is the exactpnpmcommand that installs the App's dependencies. Run it before you start the App.
App templatesLink to this section
| Template | What you get | Queries it adds | Data it needs |
|---|---|---|---|
blank (default) | One page with a heading. You build the rest. | None | None |
dashboard | A sidebar layout, three key figure cards, a filter bar, a table with 10 rows per page and a detail sheet that opens on a row. | <slug>-records | None at first. See below. |
list | A sidebar layout, a filter bar, a full-width table with 20 rows per page and a detail sheet. | <slug>-records | None at first. See below. |
detail | A sidebar layout, a filter bar, a table with 12 rows per page and a detail panel beside it. On narrow screens the detail opens as a sheet. | <slug>-records | None at first. See below. |
financial-dashboard | Five pages behind a month picker: Overview, Profit and loss, Revenue (by customer and by business area), Cash and Time, drawn as charts and tables. | <slug>-status, -periods, -kpis, -monthly-results, -profit-and-loss, -revenue-split, -cash-balance, -time-report | Eight tables in a Lakehouse named finance_app. See below. |
Every template except blank is built with React, TypeScript, Tailwind and
shadcn/ui, works on phones (the sidebar becomes a menu below 768 pixels wide)
and calls its Queries through the generated client.
Data for the dashboard, list and detail templatesLink to this section
These three show data at once. Their Query, queries/<slug>-records.sql,
generates 100 placeholder rows and reads no table of yours. It still runs in
a Lakehouse, so the Workspace needs at least one.
To show your own data:
-
Replace the SQL in
queries/<slug>-records.sql. Keep itsfilter,offsetandlimitparameters and itstotal_countcolumn. Rename the other columns as your data needs. -
Refresh the Query's reviewed schema and the App's typed client:
bashlimilake query capture sales-records --lakehouse sales -
Update
src/lib/records.tsand the components that show the columns. -
If the Workspace has more than one Lakehouse, set
APP_LAKEHOUSEinsrc/lib/limilake.tsto the one the App reads.
Data for the financial-dashboard templateLink to this section
This template reads finished figures and does no sums of its own. Before it shows anything, the Workspace needs:
- A Lakehouse named
finance_app. - Eight tables in its
appschema:status,periods,kpis,monthly_results,profit_and_loss,revenue_split,cash_balanceandtime_report, with the exact column names and types thatapps/<slug>/CONTRACT.mdlists.
CONTRACT.md explains every column, and how to compute it from Fortnox
accounting data with the BAS chart of accounts. You usually fill the
tables with a scheduled Function that rebuilds all of them
in one run. Some data is not in the books:
- Forecasts. Leave
forecastempty and the chart shows actual figures only. - Time reporting. Leave
time_reportempty and the Time page says there is no data. - Business areas. A company without them has no
arearows inrevenue_split.
An empty table is valid. Each card shows "Loading…" until its Query answers, then its figures or an empty state that names the table it reads.
Check one Query against your data:
limilake query test finance-kpis --lakehouse finance_app --param year_month=2026-10Make the App yoursLink to this section
Branding lives in three places only:
src/brand.ts: the company name, a short name, logo paths, the primary and accent colours, the locale for number and date formats, and the currency.public/: the logo files. The template ships a placeholderlogo.svg.src/styles.css: theme tokens derived from the brand colours.
Each template App also has an AGENTS.md, and a CLAUDE.md that imports it.
It tells a coding agent how to adapt the App: take the branding from the
company's website, connect the data, keep the components and the layout,
check the App at desktop and phone width, and publish. Point your agent at
the App's folder and ask it to follow that file.
To add more shadcn/ui components to the App:
npx shadcn@latest add dialog --cwd apps/salesAdd a FunctionLink to this section
limilake add function recalculate-invoiceThis writes one file, functions/recalculate-invoice/function.py. It
declares the Function with a generated id, access="private" and
run_as="caller", and has one @fn.action handler that takes a
dict[str, str] and returns one. Replace the handler with your code.
To run Functions on your machine, add the version-matched limilake[serve]
runtime to pyproject.toml and run uv lock. The command prints this step. See Functions for routes, syncs and
schedules.
Add a QueryLink to this section
limilake add query active-customersThis writes two files:
queries/active-customers.sql: placeholder SQL,SELECT 1 AS example_value.queries/active-customers.schema.json: the reviewed schema of its parameters and columns. Apps call the Query through a typed client built from this file.
After you write the SQL, refresh the schema from your data. Add --app to
let an App call the Query:
limilake query capture active-customers --lakehouse sales --app salesPick from a menuLink to this section
Run limilake add with no arguments in a terminal. It asks what to add (App,
Function or Query), then for a name, then for confirmation. The menu always
adds a blank App; use limilake add app <slug> --template <name> for a
template. Outside a terminal, or with --no-input, the bare command exits
with code 2 and names the kinds it accepts.
Run it locallyLink to this section
From the Workspace root:
limilake devThis starts every App and HTTP Function in the Workspace on your machine and prints the address of each App. Queries and Functions run against your live data. If the Workspace has several Lakehouses, pass the one the App reads:
limilake dev --lakehouse salesPublishLink to this section
Commit the new files, including the updated root package.json,
pnpm-lock.yaml and generated clients, then push to main:
git status --short
git add -- apps/sales queries package.json pnpm-lock.yaml
git commit -m "Add sales dashboard"
git push origin HEAD:mainThe push publishes the Workspace. Follow the build with
limilake publication show, then open the address that
limilake app show sales prints. See
Publish a Workspace.
Next stepsLink to this section
- Apps: who can open an App, public Apps and their limits.
- Functions: actions, HTTP routes and syncs.
- Schedules: fill the finance tables on a schedule.
- Custom domains: serve the App on your own hostname.