Skip to content

Commit

Permalink
Add missing buildId property to appRouter
Browse files Browse the repository at this point in the history
  • Loading branch information
valentinpalkovic committed Jul 4, 2023
1 parent 05de1f0 commit c16dce1
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
9 changes: 3 additions & 6 deletions code/frameworks/nextjs/src/images/next-future-image.tsx
@@ -1,13 +1,10 @@
import React from 'react';
import type * as _NextImage from 'next/image';
import { ImageContext } from './context';
import { defaultLoader } from './next-image-default-loader';

// eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-ignore import is aliased in webpack config
const FutureNextImage = require('sb-original/next/future/image') as typeof _NextImage;

const OriginalNextFutureImage = FutureNextImage.default;
import OriginalNextFutureImage from 'sb-original/next/future/image';
import { ImageContext } from './context';
import { defaultLoader } from './next-image-default-loader';

function NextFutureImage(props: _NextImage.ImageProps) {
const imageParameters = React.useContext(ImageContext);
Expand Down
2 changes: 1 addition & 1 deletion code/frameworks/nextjs/src/images/webpack.ts
Expand Up @@ -30,7 +30,7 @@ const configureImageDefaults = (baseConfig: WebpackConfig): void => {
resolve.alias = {
...resolve.alias,
'sb-original/next/future/image': require.resolve('next/future/image'),
'next/future/image': path.resolve(__dirname, './images/next-legacy-image'),
'next/future/image': path.resolve(__dirname, './images/next-future-image'),
};
}
};
Expand Down
1 change: 1 addition & 0 deletions code/frameworks/nextjs/src/routing/app-router-provider.tsx
Expand Up @@ -68,6 +68,7 @@ const AppRouterProvider: React.FC<AppRouterProviderProps> = ({ children, action,
changeByServerResponse() {
// NOOP
},
buildId: 'storybook',
tree,
focusAndScrollRef: {
apply: false,
Expand Down

0 comments on commit c16dce1

Please sign in to comment.