next.js/packages/next-codemod/transforms/__testfixtures__/remove-unstable-prefix/require.input.tsx
require.input.tsx18 lines416 B
// @ts-nocheck
/* eslint-disable */
const { unstable_cacheTag, unstable_cacheLife, revalidatePath } = require('next/cache')

export function MyComponent() {
  const tag = unstable_cacheTag('my-tag')
  const life = unstable_cacheLife('2 hours')

  // This should remain unchanged
  revalidatePath('/app')

  return (
    <div>
      <p>Using cache tag: {tag}</p>
      <p>Using cache life: {life}</p>
    </div>
  )
}
Quest for Codev2.0.0
/
SIGN IN