We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cff3d27 commit 0c945e5Copy full SHA for 0c945e5
docs/_snippets/storybook-main-pnpm-with-module-resolution.md
@@ -2,7 +2,9 @@
2
import path from 'path';
3
4
const getAbsolutePath = (packageName) =>
5
- path.dirname(require.resolve(path.join(packageName, 'package.json')));
+ path
6
+ .dirname(import.meta.resolve(path.join(packageName, 'package.json')))
7
+ .replace(/^file:\/\//, '');
8
9
export default {
10
framework: {
@@ -25,7 +27,9 @@ import type { StorybookConfig } from '@storybook/your-framework';
25
27
26
28
29
const getAbsolutePath = (packageName: string): any =>
30
31
32
33
34
const config: StorybookConfig = {
35
0 commit comments