Skip to the contentSkip to the navigation
RootsGitHubMenu
On this page

roots.lisp keys

Every key of roots.lisp in Roots 0.4.0, from the schema the toolchain validates the file against. An unknown key is an error with a suggestion; nothing in the file is evaluated.

Top level #

KeyTypeDefaultMeaning
:namenamePackage-style name: lowercase letters, digits and dashes (default: the directory name).
:titlestringHuman-readable app name (default: the name, capitalised).
:versionsemver"0.1.0"App version, MAJOR.MINOR.PATCH.
:idapp-idReverse-DNS app id, e.g. com.example.todo (default: com.example.<name>).
:descriptionstringOne-line description (manifests, package.json).
:entrypathEntry component (default: the first of src/App.vue, .roots, .lisp, .ts, .js).
:themethemeColour tokens, e.g. (:primary "#42b883" :dark (:bg "#111")).
:uselist of pathModules whose default export is installed with app.use() before mounting, e.g. ("src/router.ts").
:safelistlist of stringUtility classes to generate even when no template uses them literally.
:publicpath"public"Directory copied verbatim into DOM targets.
:iconpath"icon.png"App icon (PNG). A default icon is generated when the file does not exist.
:strictbooleanTreat unknown utility classes as errors (like --strict).
:bundlebooleantroots build: bundle each target's modules into one tree-shaken file per entry (roots dev and roots run never bundle).
:minifybooleantroots build: minify the bundle (nothing without :bundle).
:error-codesbooleanroots build: drop the text of the runtime's errors and warnings from the bundle; they read "[R208] " (like --error-codes; the codes are listed in docs/runtime.md).
:devproperty listDev server settings.
:dataproperty listroots/data: pin another SQLite WASM build (all three keys together; D164, D166).
:cspproperty listAdditions to the page's Content-Security-Policy.
:nativeproperty listNative shells for ios and android (Roots shell or Capacitor).
:targetstargetsTargets this app supports, with options: (:web () :pwa (:theme-color "#…") …).
:packagesproperty listPackage manager policy (docs/packages.md): cooldown, exemptions, overrides, hoist, registries.
:siteproperty listDocumentation site settings (roots docs).

:dev #

KeyTypeDefaultMeaning
:portinteger 1–655355173Dev server port.
:hostslist of stringExtra Host names the dev server accepts (with --host).

:data #

KeyTypeDefaultMeaning
:sqlite-versionstringThe @sqlite.org/sqlite-wasm version this app ships instead of the one the toolchain pins.
:sqlite-mjs-sha256stringSHA-256 (hex) of that version's dist/index.mjs.
:sqlite-wasm-sha256stringSHA-256 (hex) of that version's dist/sqlite3.wasm.

:csp #

KeyTypeDefaultMeaning
:trusted-typesbooleantRequire Trusted Types for script sinks (web, pwa and the Roots shells).
:connect-srclist of stringExtra origins for fetch, XHR, WebSocket and EventSource.
:img-srclist of stringExtra image origins (and "data:", "blob:").
:font-srclist of stringExtra font origins (and "data:", "blob:").
:media-srclist of stringExtra audio/video origins (and "data:", "blob:").
:frame-srclist of stringOrigins the app may show in an <iframe>.

:native #

KeyTypeDefaultMeaning
:shell:roots | :capacitor:rootsNative shell of ios and android: :roots (Roots' own, docs/native.md) or :capacitor.
:pluginslist of plugin-name:autoNative plugins JavaScript may call through RootsNative (Roots shell); only these are compiled in (default: the ones the app uses).
:backupbooleanInclude the app's data in device and cloud backups.
:app-idapp-idBundle id / application id (default: :id).
:app-namestringThe name under the app icon (default: :title).
:buildinteger 1–21000000001Build number: Android versionCode, iOS CFBundleVersion.
:android-dependencieslist of maven-coordinateGradle dependencies of your own plugins, e.g. "androidx.biometric:biometric:1.1.0".
:android-permissionslist of android-permissionAndroid permissions your own plugins need, e.g. "android.permission.VIBRATE".

:packages #

KeyTypeDefaultMeaning
:cooldowninteger 0–3657Days a version must have been published before it is installed (SC-3). 0 disables the cooldown.
:exemptlist of property listPackages exempt from the cooldown, each with a reason: ((:package "x" :reason "…")).
:overrideslist of property listForce one version (or range) of a package everywhere in the graph, with a reason (SC-13).
:hoistlist of property listPackages made visible to every dependency (node_modules/.roots/node_modules), with a reason (SC-12).
:registrystringDefault registry URL (else .npmrc registry=, else https://registry.npmjs.org/).
:registrieslist of property listScope → registry. A mapped scope never falls back to another registry (SC-7).
:strictbooleanFail (instead of warn) when a packument disagrees with the tarball's package.json (SC-5).
:buildslist of property listPackages whose install scripts may be approved. When this key is present, an approval in roots.lock counts only for a package listed here, so a change to roots.lock alone cannot approve a script (SC-1).
:verify-agebooleanCheck the publish time of every locked version against the cooldown before installing (one metadata request per package), so a change to roots.lock alone cannot pin a version inside the cooldown (SC-3).
:script-timeoutinteger 1–3600300Seconds an approved install script may run (SC-2).

:site #

KeyTypeDefaultMeaning
:originstringScheme and host of the published site, e.g. https://example.github.io (canonical links, sitemap).
:basestring"/"Path of the site below the origin, e.g. /roots/ (canonical links, sitemap, the root 404 page).
:repositorystringURL of the source repository (links to files, "Edit this page").
:edit-branchstring"main"Branch that "Edit this page" links to.
:versionspath"versions.lisp"The published versions built from older commits.
:repo-rootstring".."The repository's root, relative to the project (files outside the project that pages quote or link).

Targets #

Options inside :targets (:web (…) :pwa (…)).

:web #

KeyTypeDefaultMeaning
:outpathOutput directory (default dist/web).
:bundleinherit-boolean:inheritBundle this target's modules into one file per entry (default: the top-level :bundle).
:minifyinherit-boolean:inheritMinify this target's bundle (default: the top-level :minify).

:pwa #

KeyTypeDefaultMeaning
:outpathOutput directory (default dist/pwa).
:bundleinherit-boolean:inheritBundle this target's modules into one file per entry (default: the top-level :bundle).
:minifyinherit-boolean:inheritMinify this target's bundle (default: the top-level :minify).
:theme-colorcolorBrowser UI colour (default: the theme's primary colour).
:background-colorcolorSplash screen background (default: the theme's bg colour).
:short-namestringName under the home-screen icon (default: :title).
:display:standalone | :fullscreen | :minimal-ui | :browser:standaloneDisplay mode.
:precache-excludelist of pathFiles (or directories, with a trailing /) the service worker does not precache.

:ext #

KeyTypeDefaultMeaning
:outpathOutput directory (default dist/ext).
:bundleinherit-boolean:inheritBundle this target's modules into one file per entry (default: the top-level :bundle).
:minifyinherit-boolean:inheritMinify this target's bundle (default: the top-level :minify).
:permissionslist of string("storage")Extension permissions; storage backs roots/platform storage.
:browserslist of :chrome | :firefox(:chrome :firefox)Browsers to emit manifest keys for.
:gecko-idstringFirefox add-on id (default: derived from :id, e.g. todo@example.com).
:popup-widthinteger 25–800360Popup width in CSS pixels.
:popup-heightinteger 25–600480Popup height in CSS pixels.

:ios #

KeyTypeDefaultMeaning
:outpathOutput directory (default dist/ios).
:bundleinherit-boolean:inheritBundle this target's modules into one file per entry (default: the top-level :bundle).
:minifyinherit-boolean:inheritMinify this target's bundle (default: the top-level :minify).
:shell:roots | :capacitorThis target's native shell (default: :native :shell).
:app-idapp-idBundle id (default: :native :app-id, then :id).
:app-namestringDisplay name (default: :title).
:pluginslist of capacitor-plugin("@capacitor/preferences" "@capacitor/clipboard" "@capacitor/browser")Capacitor plugins added to package.json (pinned versions; Capacitor shell only).

:android #

KeyTypeDefaultMeaning
:outpathOutput directory (default dist/android).
:bundleinherit-boolean:inheritBundle this target's modules into one file per entry (default: the top-level :bundle).
:minifyinherit-boolean:inheritMinify this target's bundle (default: the top-level :minify).
:shell:roots | :capacitorThis target's native shell (default: :native :shell).
:app-idapp-idApplication id (default: :native :app-id, then :id).
:app-namestringDisplay name (default: :title).
:pluginslist of capacitor-plugin("@capacitor/preferences" "@capacitor/clipboard" "@capacitor/browser")Capacitor plugins added to package.json (pinned versions; Capacitor shell only).

:term #

KeyTypeDefaultMeaning
:outpathOutput directory (default dist/term).
:bundleinherit-boolean:inheritBundle this target's modules into one file per entry (default: the top-level :bundle).
:minifyinherit-boolean:inheritMinify this target's bundle (default: the top-level :minify).