Blog

Using typescript#

To use typescript pages or components you can just change the components files extensions to .tsx and install the react and node typings:

bash
1
yarn add -D typescript @types/node

Then after you run npm run dev nextjs will create a tsconfig.json file automatically and you can import typescript files inside you mdx pages.

Previous
Export to pdf
Using typescript