Packages
A spellchecker for Elixir, made with Bun and cspell
Current section
Files
Jump to
Current section
Files
priv/bun/node_modules/cspell-lib/dist/lib/util/fileReader.js
import { toFileURL } from 'cspell-io';
import { readTextFile } from '../fileSystem.js';
import { toIterableIterator } from './iterableIteratorLib.js';
export async function readLines(url, encoding = 'utf8') {
url = toFileURL(url);
const content = await readTextFile(url, encoding);
return toIterableIterator(content.split(/\r?\n/g));
}
//# sourceMappingURL=fileReader.js.map