i want to use custom fonts in my project
Unanswered
Entlebucher Mountain Dog posted this in #help-forum
Entlebucher Mountain DogOP
import font in global css
and then i trying to render the font in layout file
and then i trying to render the font in layout file
8 Replies
Entlebucher Mountain DogOP
@Clown
In this case, you don't
you go into tailwind.config.ts
and under
extend
you enter
fontFamily: {
sans: ["SutonnyMJ"]
},
tailwind.config.ts
For Local Fonts(custom):
https://nextjs.org/docs/pages/building-your-application/optimizing/fonts#local-fonts
https://nextjs.org/docs/pages/building-your-application/optimizing/fonts#local-fonts
Combine this with this if you want to use tailwind css. Although for your use case the above link should be enough.
https://nextjs.org/docs/pages/building-your-application/optimizing/fonts#with-tailwind-css
https://nextjs.org/docs/pages/building-your-application/optimizing/fonts#with-tailwind-css