You are able to extend the custom css with hover, focus, group-hover, responsive variants class in tailwind.

https://tailwindcss.com/docs/functions-and-directives/#variants

          <section>
<div>
<h2 class="banana hover:chocolate">
some text here
</h2>
</div>
</section>
  @variants hover, focus {
.banana {
color: yellow;
}
.chocolate {
color: brown;
}
}

Tailwind will generate css for you:

.banana {
color: yellow;
}
.chocolate {
color: brown;
}
.focus\:banana:focus {
color: yellow;
}
.focus\:chocolate:focus {
color: brown;
}
.hover\:banana:hover {
color: yellow;
}
.hover\:chocolate:hover {
color: brown;
}

[Tailwind] Extending Tailwind with Responsive Custom Utility Classes的更多相关文章

  1. [Tailwind] Create Custom Utility Classes in Tailwind

    In this lesson, we learn how to generate custom utility classes in tailwind. We add new properties t ...

  2. [Tailwind] Abstract Utility Classes to BEM Components in Tailwind

    When creating UIs with utility classes, a lot of repetition can occur within the HTML markup. In thi ...

  3. Top 15 Java Utility Classes

    In Java, a utility class is a class that defines a set of methods that perform common functions. Thi ...

  4. Utility Classes Are Evil

    原文地址:http://alphawang.com/blog/2014/09/utility-classes-are-evil/ This post is a summary of this arti ...

  5. add a private constructor to hide the implicit public one(Utility classes should not have public constructors)

    sonarlint提示add a private constructor to hide the implicit public one Utility classes should not have ...

  6. Implement Custom Business Classes and Reference Properties实现自定义业务类和引用属性(EF)

    In this lesson, you will learn how to implement business classes from scratch. For this purpose, the ...

  7. Implement Custom Business Classes and Reference Properties 实现自定义业务类和引用属性(XPO)

    In this lesson, you will learn how to implement business classes from scratch. For this purpose, the ...

  8. [Tailwind] Control What Variations are Generated for Each Utility Class Module in Tailwind

    In this lesson, we learn how to control what utility classes are generated for each utility class mo ...

  9. [Tailwind] Get started with Tailwindcss

    In this lesson, we learn how to generate CSS utility classes from Tailwind's JavaScript config file. ...

随机推荐

  1. URL重写及ASP.NET路由、Http处理模块、程序等

    这段时间在学习ASP.NET路由.HTTP处理等内容,了解了一些,但又未完全弄懂,似是而非,不管如何,作一总结,供日后借鉴和修改. 一.IIS6和IIS7经典模式和集成模式 在IIS6及IIS7经典模 ...

  2. luogu1403 约数研究

    题目大意:给出n,求1~n所有数的约数个数的和. 将“1~n所有数的约数”的模板中的factor[i*j].push_back(i)改为FactorCnt[i*j]++,最后再求一次和即可. #inc ...

  3. js 数组包含

    function(arr,element){ return new RegExp('(^|,)'+element.toString()+'(,|$)').test(arr.toString()); }

  4. 9.13[XJOI] NOIP训练32

    今日9.13 洛谷打卡:小吉(今天心情不错,决定取消密码) (日常记流水账) 上午 今天听说是鏼鏼的题目,题面非常的清真啊,也没有当初以为的爆零啊 T1 排排坐 非常非常清真的模拟或是结论题,再次将难 ...

  5. 3.TinkPHP中的模型

    1.配置数据库的连接设置 数据库的连接配置项可以在系统的主配置文件中 2.什么是模型? 模型是MVC 三大组成部分的M,作用是负责与数据表达额交互(CRUD) 3.模型的创建 命名规范:不带前缀的标明 ...

  6. css3中的animation属性

    作用:通过给元素添加animation属性,可以赋予该元素动画效果. <!DOCTYPE html><html>    <head>        <styl ...

  7. javascript的基础知识及面向对象和原型属性

    自己总结一下javascript的基础知识,希望对大家有用,也希望大家来拍砖,毕竟是个人的理解啊 1.1 类型检查:typeof(验证数据类型是:string) var num = 123; cons ...

  8. 安装pywin32

    1.下载pywin32:https://sourceforge.net/projects/pywin32/files/pywin32/ 2.安装: 安装过程中报错:Python version 2.7 ...

  9. 部署Seafile服务

    介绍 官网:https://www.seafile.com 客户端/服务端下载:https://www.seafile.com/download/ 中文安装教程(MySQL版):http://manu ...

  10. Spring DATA MongoDB @DBref查询,or和and联合查询

    @DBref文档关联,在按该类型查询的时候,在字段名后加上关联表的字段名即可,如: Criteria.where("bloggroup.$id"), $id代表关联表的oid字段. ...