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

feat: rename next.js adapter package #6896

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft

Conversation

orinokai
Copy link

@orinokai orinokai commented Oct 23, 2024

Summary

Update to use new package name for our Next.js Adapter, which is moving to the @opennextjs scope.

To do

orinokai and others added 2 commits October 23, 2024 13:27
We're not calling it a "runtime" anymore.

Plus this was super leaky anyway, assuming that any auto-installed build plugin is a "runtime".
@@ -34,7 +34,7 @@ export const getPluginsToAutoInstall = (
pluginsInstalled: string[] = [],
pluginsRecommended: string[] = [],
) => {
const nextRuntime = '@netlify/plugin-nextjs'
const nextRuntime = '@opennextjs/netlify'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This took me a while to understand — this is part of 'init' i.e. used in ntl init and related scenarios, and its purpose is to literally auto-install the plugin on the site via the Netlify API if it isn't already installed and we've detected that it should be. So it's OK to just update this name and not "handle" the old name in any way.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

... although, wait, isn't there a case like this?

  1. next.js site exists today with @netlify/plugin-nextjs installed
  2. we release this cli change
  3. user clones their repo, runs ntl init, it checks and finds that @opennextjs/netlify is not auto-installed (even though @netlify/plugin-nextjs is) and auto-installs @opennextjs/netlify.
  4. user has both plugins installed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants