
Solution retrospective
I don't know how to import custom font using nextjs tailwind
Please log in to post a comment
Log in with GitHubCommunity feedback
- @nuraf9607
- Visit the Google Fonts website.
- Select a font that suits your needs.
- Click on "Get Font."
- Click on "Get Embedded Code."
- Choose the @import option.
- You'll find a link like this:
@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap');
- Copy the @import link and paste it at the top of your CSS file.
- You've now successfully imported the font.
- To use it, refer back to where you copied the link. Below it, you’ll see the appropriate
font-family
value to use in your CSS.
Join our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord