Next.js · Middle · Question 66 of 75
A monorepo package @acme/ui ships untranspiled TypeScript. How do you use it in a Next.js app?
- ✓Correct answer: Add it to
transpilePackagesinnext.config.ts - 2Copy its files into
app/ - 3It's impossible; publish it as compiled JS first
Explanation
transpilePackages lets Next.js compile dependencies from local packages or node_modules, replacing the old next-transpile-modules plugin.