Skip to content

Commit 71b49d5

Browse files
committed
stop at 80char/line, compact ast logging
1 parent 585051f commit 71b49d5

File tree

1 file changed

+10
-18
lines changed

1 file changed

+10
-18
lines changed

README.md

+10-18
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ Queries and determine if a media query matches a given set of values.
2525

2626
### Matching
2727

28-
The `match()` method lets you compare a media query expression with a JavaScript object and determine if a media query matches a given set of values.
28+
The `match()` method lets you compare a media query expression with a JavaScript
29+
object and determine if a media query matches a given set of values.
2930

3031
```javascript
3132
var mediaQuery = require('css-mediaquery');
@@ -40,7 +41,9 @@ console.log(isMatch); // => true
4041

4142
### Parsing
4243

43-
Existing CSS Parsers don't do a great job at parsing the details of media queries. That's where `css-mediaquery` shines. You can parse a media query expression and get an AST back by using the `parse()` method.
44+
Existing CSS Parsers don't do a great job at parsing the details of media
45+
queries. That's where `css-mediaquery` shines. You can parse a media query
46+
expression and get an AST back by using the `parse()` method.
4447

4548
```javascript
4649

@@ -52,21 +55,9 @@ var ast = mediaQuery.parse('screen and (min-width: 48em)');
5255
The `ast` variable will have the following payload:
5356

5457
```javascript
55-
56-
[
57-
{
58-
"inverse": false,
59-
"type": "screen",
60-
"expressions": [
61-
{
62-
"modifier": "min",
63-
"feature": "width",
64-
"value": "48em"
65-
}
66-
]
67-
}
68-
]
69-
58+
[ { inverse: false, type: 'screen', expressions: [
59+
{ modifier: 'min', feature: 'width', value: '48em' }
60+
] } ]
7061
```
7162

7263
This package was written with care to following the W3C Recommendations for
@@ -76,7 +67,8 @@ a common unit before comparing them.
7667

7768

7869
The values specified to check a media query string against should be thought of
79-
as if they are the current state of a device/browser. A `type` value _must_ be specified, and it can _not_ be `"all"`.
70+
as if they are the current state of a device/browser. A `type` value _must_ be
71+
specified, and it can _not_ be `"all"`.
8072

8173

8274
[w3c-mq]: http://www.w3.org/TR/css3-mediaqueries/

0 commit comments

Comments
 (0)