You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
vitepress/__tests__/e2e/external-data/files.data.ts

11 lines
256 B

import { readFile } from 'node:fs/promises'
export default {
watch: '../../fixtures/external-data/**/*.json',
async load(files: string[]) {
return Promise.all(
files.map(async (file) => JSON.parse(await readFile(file, 'utf-8')))
)
}
}