Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Next.js: Fix next/image usage in latest Next.js release #23296

Merged
merged 2 commits into from Jul 4, 2023

Conversation

valentinpalkovic
Copy link
Contributor

@valentinpalkovic valentinpalkovic commented Jul 4, 2023

Closes #23287

What I did

It was not possible to override the default component from next/image anymore, because the component was defined via Object.defineProperty to prevent overrides. The override now happens during build time instead of runtime.

How to test

  • not necessary, since the chromatic snapshots will fail, if the image component is not working.

Checklist

  • Make sure your changes are tested (stories and/or unit, integration, or end-to-end tests)
  • Make sure to add/update documentation regarding your changes
  • If you are deprecating/removing a feature, make sure to update
    MIGRATION.MD

Maintainers

  • If this PR should be tested against many or all sandboxes,
    make sure to add the ci:merged or ci:daily GH label to it.
  • Make sure this PR contains one of the labels below.

["cleanup", "BREAKING CHANGE", "feature request", "bug", "documentation", "maintenance", "dependencies", "other"]

@valentinpalkovic valentinpalkovic changed the title Fix next/image, next/future/image and next/legacy/image usage in latest Next.js release Fix next/image usage in latest Next.js release Jul 4, 2023
@valentinpalkovic valentinpalkovic self-assigned this Jul 4, 2023
@valentinpalkovic valentinpalkovic added bug nextjs ci:daily Run the CI jobs that normally run in the daily job. labels Jul 4, 2023
@valentinpalkovic valentinpalkovic changed the title Fix next/image usage in latest Next.js release Next.js: Fix next/image usage in latest Next.js release Jul 4, 2023
@valentinpalkovic valentinpalkovic force-pushed the valentin/fix-next-images-in-latest-release branch 2 times, most recently from d4e9976 to e14f5f9 Compare July 4, 2023 10:55
@valentinpalkovic valentinpalkovic force-pushed the valentin/fix-next-images-in-latest-release branch from e14f5f9 to c16dce1 Compare July 4, 2023 11:25
@valentinpalkovic valentinpalkovic merged commit d4a3a23 into next Jul 4, 2023
97 of 99 checks passed
@valentinpalkovic valentinpalkovic deleted the valentin/fix-next-images-in-latest-release branch July 4, 2023 12:11
@github-actions github-actions bot mentioned this pull request Jul 4, 2023
4 tasks
@valentinpalkovic valentinpalkovic added the patch:yes Bugfix & documentation PR that need to be picked to main branch label Jul 4, 2023
shilman pushed a commit that referenced this pull request Jul 4, 2023
…in-latest-release

Next.js: Fix next/image usage in latest Next.js release

(cherry picked from commit d4a3a23)
shilman pushed a commit that referenced this pull request Jul 4, 2023
…n-latest-release

Next.js: Fix next/image usage in latest Next.js release

(cherry picked from commit d4a3a23)
@github-actions github-actions bot added patch:done Patch/release PRs already cherry-picked to main/release branch labels Jul 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug ci:daily Run the CI jobs that normally run in the daily job. nextjs patch:done Patch/release PRs already cherry-picked to main/release branch patch:yes Bugfix & documentation PR that need to be picked to main branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: Storybook incompatible with Next.js 13.4.8
1 participant