UNPKG

588 BJavaScriptView Raw
1import "core-js/modules/es.promise.js";
2import path from 'path';
3import { findDistEsm } from '@storybook/core-common';
4export async function webpackFinal(webpackConfig, options) {
5 var svelteOptions = await options.presets.apply('svelteOptions', {}, options);
6 webpackConfig.module.rules.push({
7 test: /\.svelte$/,
8 loader: path.resolve(`${__dirname}/svelte-docgen-loader`),
9 enforce: 'post',
10 options: svelteOptions
11 });
12 return webpackConfig;
13}
14export var previewAnnotations = function (entry = []) {
15 return [...entry, findDistEsm(__dirname, 'client/docs/config')];
16};
\No newline at end of file