Skip to content

Commit ff07a6d

Browse files
cursoragenteps1lon
andcommitted
Remove addTransitionType availability check
addTransitionType is in React Canary and therefore always available in Next.js App Router. Co-authored-by: Sebastian "Sebbie" Silbermann <silbermann.sebastian@gmail.com>
1 parent db6d8a5 commit ff07a6d

File tree

1 file changed

+0
-6
lines changed
  • packages/next/src/client/app-dir

1 file changed

+0
-6
lines changed

packages/next/src/client/app-dir/link.tsx

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -512,12 +512,6 @@ export default function LinkComponent(
512512
const formattedHref = formatStringOrUrl(resolvedHref)
513513

514514
if (process.env.NODE_ENV !== 'production') {
515-
if (transitionTypes && typeof React.addTransitionType !== 'function') {
516-
warnOnce(
517-
'`transitionTypes` are passed to a <Link>, but `React.addTransitionType` is not available. ' +
518-
'You need to enable `experimental.viewTransition` or `experimental.gestureTransition` to use Transition types.'
519-
)
520-
}
521515
if (props.locale) {
522516
warnOnce(
523517
'The `locale` prop is not supported in `next/link` while using the `app` router. Read more about app router internalization: https://nextjs.org/docs/app/building-your-application/routing/internationalization'

0 commit comments

Comments
 (0)