Replace Ruby Vite plugins (#35195)

Co-authored-by: Renaud Chaput <renchap@gmail.com>
This commit is contained in:
Echo
2025-07-17 12:04:04 +02:00
committed by GitHub
parent 19626ad89f
commit 9e6a9efe10
6 changed files with 153 additions and 106 deletions

View File

@@ -1,3 +1,5 @@
import { resolve } from 'node:path';
import type { StorybookConfig } from '@storybook/react-vite';
const config: StorybookConfig = {
@@ -26,6 +28,12 @@ const config: StorybookConfig = {
'oops.png',
].map((path) => ({ from: `../public/${path}`, to: `/${path}` })),
],
viteFinal(config) {
// For an unknown reason, Storybook does not use the root
// from the Vite config so we need to set it manually.
config.root = resolve(__dirname, '../app/javascript');
return config;
},
};
export default config;