Skip to content

Deno

DARST uses Deno for security and performance. Here is everything you should know:

Install

You should have Deno installed. You can install it from the official website or copy and paste the following command.

Terminal window
curl -fsSL https://deno.land/install.sh | sh

Package management

While DARST uses Deno for scripts and tasks, NPM is still used for package management as it offers better compatibility.

So any packages installed or removed should be done with NPM

Terminal window
npm install lodash

Tasks and Scripts

Deno is used for running tasks and scripts within DARST. Tasks for astro and shadcn CLI’s have been added.

Terminal window
deno task astro add vercel

Linting and Formatting

Deno is also used for linting and formatting the source code. Experimental flags been enabled to also allow for formatting .astro files.

Terminal window
deno task check

Formatting and linting configuration can be changed from deno.json.

deno.json
{
...
"fmt": {
"useTabs": true,
"semiColons": true,
"singleQuote": false
},
"unstable": ["fmt-component"]
}