histoire
Version:
A fast story book powered by Vite
15 lines (14 loc) • 579 B
JavaScript
import { getHistoireBrowserRunConfig } from '../vitest-browser-config/run-config.js';
/**
* Builds the Vitest browser config of a story collection run.
* @param ctx The histoire context.
* @param specFiles The generated collection specs, also used as optimizer entries.
* @param channelPlugin The plugin exposing the collection results endpoint.
*/
export async function getCollectionVitestConfig(ctx, specFiles, channelPlugin) {
return getHistoireBrowserRunConfig(ctx, {
collecting: true,
entries: specFiles,
plugins: [channelPlugin],
});
}