mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-03-11 02:12:21 -05:00
Fixed storybook failing to load due @tryghost/nql
usage (#18453)
no refs storybook was failing to load due to `@tryghost/nql` usage and the global `vite` config not being used
This commit is contained in:
parent
84520f86f7
commit
2373a51ee4
1 changed files with 3 additions and 0 deletions
|
@ -1,3 +1,4 @@
|
|||
import {resolve} from "path";
|
||||
import type { StorybookConfig } from "@storybook/react-vite";
|
||||
const config: StorybookConfig = {
|
||||
stories: ["../src/**/*.mdx", "../src/**/*.stories.@(js|jsx|ts|tsx)"],
|
||||
|
@ -20,6 +21,8 @@ const config: StorybookConfig = {
|
|||
async viteFinal(config, options) {
|
||||
config.resolve.alias = {
|
||||
crypto: require.resolve('rollup-plugin-node-builtins'),
|
||||
// @TODO: Remove this when @tryghost/nql is updated
|
||||
mingo: resolve(__dirname, '../../../node_modules/mingo/dist/mingo.js')
|
||||
}
|
||||
return config;
|
||||
},
|
||||
|
|
Loading…
Add table
Reference in a new issue