Skip to content

Ala-Younes/dojo-blog

Repository files navigation

dojo-blog

How to add google font in tailwind

  • The import of the url on the top
@import url("https://fonts.googleapis.com/css2?family=Quicksand:wght@300;400;500;600;700&display=swap");
@tailwind base;
@tailwind components;
@tailwind utilities;
  • Add Font Name in Tailwind Config File
/** @type {import('tailwindcss').Config} */
export default {
  content: ["./index.html", "./src/**/*.{js,ts,jsx,tsx}"],
  theme: {
    extend: {
      fontFamily: {
        primary: ["Quicksand"],
      },
    },
  },
  plugins: [],
};
  • Step 4: Use Your Google Fonts in HTML
<h1
class="text-2xl
font-primary
">
This heading is using Poppins Fonts
</h1>
  • Optional Step 5 : Use it on your entire web page.
<body
class="font-primary"
>

Git Ignore

add it to the gitignore file

  • example : data/db.json
git rm --cached data/db.json

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published