mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-07 07:21:17 +08:00
Apply the same fix for vue3 webpack preset
This commit is contained in:
parent
10cfadd627
commit
05dfc5c4c9
@ -24,6 +24,12 @@ export const webpack: StorybookConfig['webpack'] = (config) => {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
test: /\.ts$/,
|
test: /\.ts$/,
|
||||||
|
// This exclude & its .tsx counterpart below is a hack
|
||||||
|
// for storybook's sandboxing setup, which uses .ts
|
||||||
|
// story files that get processed by esbuild-loader.
|
||||||
|
// This rule is too permissive, but since we don't know
|
||||||
|
// the user's project setup, it's hard to make it specific!
|
||||||
|
exclude: [/template-stories/],
|
||||||
use: [
|
use: [
|
||||||
{
|
{
|
||||||
loader: require.resolve('ts-loader'),
|
loader: require.resolve('ts-loader'),
|
||||||
@ -36,6 +42,7 @@ export const webpack: StorybookConfig['webpack'] = (config) => {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
test: /\.tsx$/,
|
test: /\.tsx$/,
|
||||||
|
exclude: [/template-stories/],
|
||||||
use: [
|
use: [
|
||||||
{
|
{
|
||||||
loader: require.resolve('ts-loader'),
|
loader: require.resolve('ts-loader'),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user