TypeScript Integration

Learn to configure Next.js with TypeScript, and learn about customization using Babel and webpack configurations.

TypeScript configuration in Next.js

The Next.js source code is written in TypeScript and natively provides high-quality type definitions to make our developer experience even better. Configuring TypeScript as the default language for our Next.js app is very easy; we just have to create a TypeScript configuration file (tsconfig.json) inside the root of our project. If we try to run, we’ll see the following output:

Create a free account to view this lesson.

By signing up, you agree to Educative's Terms of Service and Privacy Policy