Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/ayonli_jsext/lib.deno.d.ts>Deno.mkdirSync

A JavaScript extension package for building strong and modern applications.
Latest
function Deno.mkdirSync
allow-write
import { Deno } from "https://deno.land/x/ayonli_jsext@v0.9.72/lib.deno.d.ts";
const { mkdirSync } = Deno;

Synchronously creates a new directory with the specified path.

Deno.mkdirSync("new_dir");
Deno.mkdirSync("nested/directories", { recursive: true });
Deno.mkdirSync("restricted_access_dir", { mode: 0o700 });

Defaults to throwing error if the directory already exists.

Requires allow-write permission.

Parameters

path: string | URL
optional
options: MkdirOptions