Skip to content

Commit

Permalink
Move virtualModule files into @storybook/core-webpack
Browse files Browse the repository at this point in the history
  • Loading branch information
valentinpalkovic committed Nov 20, 2023
1 parent c546fd5 commit 5021bf4
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions code/lib/core-webpack/src/virtual-module-mapping.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ export const getVirtualModuleMapping = async (options: Options) => {
virtualModuleMapping[rendererInitEntry] = `import '${slash(rendererName)}';`;

const entryTemplate = await readTemplate(
join(__dirname, '..', '..', 'templates', 'virtualModuleEntry.template.js')
join(__dirname, '..', 'templates', 'virtualModuleEntry.template.js')
);

previewAnnotations.forEach((previewAnnotationFilename: string | undefined) => {
Expand All @@ -93,7 +93,7 @@ export const getVirtualModuleMapping = async (options: Options) => {
});
if (stories.length > 0) {
const storyTemplate = await readTemplate(
join(__dirname, '..', '..', 'templates', 'virtualModuleStory.template.js')
join(__dirname, '..', 'templates', 'virtualModuleStory.template.js')
);
// NOTE: this file has a `.cjs` extension as it is a CJS file (from `dist/cjs`) and runs
// in the user's webpack mode, which may be strict about the use of require/import.
Expand Down

0 comments on commit 5021bf4

Please sign in to comment.