Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How are browserslist queries combined in a multi-line browserslist configuration?

Browserslist documentation gives this example config:

{
  "browserslist": [
    "last 1 version",
    "> 1%",
    "maintained node versions",
    "not dead"
  ]
}

How are these lines combined into a single query? Query composition names three operators: or, and, and not, but the documentation does not say which, if any, is used to combine the queries in a config. How are these queries interpreted? I want to know the matching browsers.

like image 503
Dmitry Minkovsky Avatar asked Jan 22 '19 15:01

Dmitry Minkovsky


2 Answers

End of line is used as union combiner

parse config content

like image 173
Viktor Voloshin Avatar answered Sep 21 '22 16:09

Viktor Voloshin


This is my understanding of why it's the Union type from the docs enter image description here

like image 36
Ivan Avatar answered Sep 22 '22 16:09

Ivan