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

x/ddu_vim/deps.ts>fn.getfsize

Dark deno-powered UI framework for neovim/Vim
Go to Latest
function fn.getfsize
import { fn } from "https://deno.land/x/ddu_vim@v4.0.0/deps.ts";
const { getfsize } = fn;

The result is a Number, which is the size in bytes of the given file {fname}. If {fname} is a directory, 0 is returned. If the file {fname} can't be found, -1 is returned. If the size of {fname} is too big to fit in a Number then -2 is returned.

Can also be used as a method:

GetFilename()->getfsize()

Parameters

denops: Denops
fname: unknown

Returns

Promise<number>