How do you define attribute selectors in SASS?

后端 未结 2 1082
抹茶落季
抹茶落季 2021-02-03 16:19

In CSS, you can do this:

input[type=submit] {
  // properties
}

It\'s a very useful for styling form buttons.

How do you do the same th

2条回答
  •  一生所求
    2021-02-03 17:07

    You can also nest it like this

    input
      &[type="submit"]
        .... 
      &[type="search"]
        .... 
    

提交回复
热议问题