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

std/fs/_util.ts>isSubdir

Deno standard library
Go to Latest
The Standard Library has been moved to JSR. See the blog post for details.
function isSubdir
import { isSubdir } from "https://deno.land/std@0.164.0/fs/_util.ts";

Test whether or not dest is a sub-directory of src

Parameters

src: string | URL

src file path

dest: string | URL

dest file path

optional
sep: string = [UNSUPPORTED]

path separator

Returns

boolean