Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

tailwind.config.js

//global.css
@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@300;400;500;600;700;800&display=swap');
@tailwind base;
@tailwind components;
@tailwind utilities;


/** @type {import('tailwindcss').Config} */
module.exports = {
  content: ['./pages/**/*.{js,ts,jsx,tsx}', './components/**/*.{js,ts,jsx,tsx}', './app/**/*.{js,ts,jsx,tsx}'],
  theme: {
    screens: {
      xs: '320px',
      sm: '375px',
      lsm: '425px',
      md: '768px',
      lg: '1024px',
      xl: '1280px',
      '2xl': '1536px',
    },
    extend: {
      colors: {
        primary: '#fa9900',
        headingColor: '#666666',
        textColor: '#999',
      },
      fontFamily: {
        primary: ['Nunito', 'sans-serif'],
      },
    },
  },
  plugins: [],
};
Comment

tailwind config

npx tailwindcss init


//index.css
@tailwind base;
@tailwind components;
@tailwind utilities;

//tailwind.config.js
module.exports = {
  content: [
    "./src/**/*.{js,jsx,ts,tsx}",
  ],
  theme: {
    extend: {},
  },
  plugins: [],
}
Comment

Tailwindcss config

npx tailwindcss init
Comment

tailwind config

Next js 


module.exports = {
  content: [
    "./pages/**/*.{js,ts,jsx,tsx}",
    "./components/**/*.{js,ts,jsx,tsx}",
    "./scr/**/*.{js,ts,jsx,tsx}",
  ],
  theme: {
    extend: {},
  },
  plugins: [],
};
Comment

tailwind custom config file

module.exports = {
  content: ['./src/**/*.{html,js}'],
  theme: {
    colors: {
      'blue': '#1fb6ff',
      'purple': '#7e5bef',
      'pink': '#ff49db',
      'orange': '#ff7849',
      'green': '#13ce66',
      'yellow': '#ffc82c',
      'gray-dark': '#273444',
      'gray': '#8492a6',
      'gray-light': '#d3dce6',
    },
    fontFamily: {
      sans: ['Graphik', 'sans-serif'],
      serif: ['Merriweather', 'serif'],
    },
    extend: {
      spacing: {
        '8xl': '96rem',
        '9xl': '128rem',
      },
      borderRadius: {
        '4xl': '2rem',
      }
    }
  },
}
Comment

Tailwind Config File

module.exports = {
  content: ['./dist/*.html'],
  theme: {
    extend: {},
  },
  variants: {
    extend: {},
  },
  plugins: [],
}
Comment

PREVIOUS NEXT
Code Example
Javascript :: momentjs range 
Javascript :: javascript rupiah currency format 
Javascript :: new line in p tag react 
Javascript :: get offset from timezone javascript 
Javascript :: unshift 
Javascript :: download json file from s3 
Javascript :: chrome add a bookmark that appends to current url 
Javascript :: lwc quick action close 
Javascript :: js markdown to html 
Javascript :: convert date time to date function javascript 
Javascript :: css lint 
Javascript :: jquery noconflict 
Javascript :: get closest element id jquery 
Javascript :: javascript pick random attribute from object 
Javascript :: how to integrate redux dev tool to react application 
Javascript :: nodejs catch uncaught exception 
Javascript :: substring javascript 
Javascript :: find in string javascript 
Javascript :: jquery validation manually trigger 
Javascript :: json api testing 
Javascript :: javascript js isNumber 
Javascript :: react background image opacity 
Javascript :: how to double array data in js 
Javascript :: vue axios catch error 
Javascript :: change href without reloading page js 
Javascript :: javascript array push element at index 
Javascript :: moment().toDate(); 
Javascript :: add react to existing project 
Javascript :: jquery on click outsile hide div 
Javascript :: javascript input prompt example 
ADD CONTENT
Topic
Content
Source link
Name
1+3 =