import { fn } from "https://deno.land/x/ddc_vim@v4.0.2/deps.ts";
const { filereadable } = fn;
The result is a Number, which is TRUE
when a file with the
name {file} exists, and can be read. If {file} doesn't exist,
or is a directory, the result is FALSE
. {file} is any
expression, which is used as a String.
If you don't care about the file being readable you can use
glob()
.
{file} is used as-is, you may want to expand wildcards first:
echo filereadable('~/.vimrc')
0
echo filereadable(expand('~/.vimrc'))
1
Can also be used as a method
:
GetName()->filereadable()
Obsolete name: file_readable().
Parameters
denops: Denops