Index importing system broken

I’ve asked v0 to refactor my codes according to Next.js best practices. It recommends index re-export, with barrel file, so there’s no need to specify file extensions. I’ve tried

  • export { Header } from “@/components/common/header”
  • export { Header } from “./header”
  • export { Header } from “header”

I’ve also asked v0 to fix tsconfig.json.

None of them worked. What’s the right way to do this please?

Hi, @4n6h4x0r! Welcome to the Vercel Community :waving_hand:

How have you imported your existing code? :slight_smile: That might be a good place to start so that it has full context!

I’ll also share this post that may be helpful: