Skip to content

Commit 0cadbb4

Browse files
committed
Update dev-dependencies
1 parent ab66c9a commit 0cadbb4

File tree

11 files changed

+141
-139
lines changed

11 files changed

+141
-139
lines changed

.prettierignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
coverage/
22
hast-util-select.js
33
hast-util-select.min.js
4+
*.json
5+
*.md

lib/any.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ function ruleSet(query, node, state) {
4242

4343
function rule(query, tree, state) {
4444
var collect = collector(state.one)
45-
var opts = {
45+
var options = {
4646
schema: state.space === 'svg' ? svg : html,
4747
language: undefined,
4848
direction: 'ltr',
@@ -57,7 +57,7 @@ function rule(query, tree, state) {
5757
throw new Error('Expected selector without nesting')
5858
}
5959

60-
nest(query, tree, 0, null, configure(query, opts))
60+
nest(query, tree, 0, null, configure(query, options))
6161

6262
return collect.result
6363

lib/attribute.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -55,27 +55,27 @@ function exact(query, node, info) {
5555

5656
// `[attr~=value]`
5757
function spaceSeparatedList(query, node, info) {
58-
var val
58+
var value
5959

6060
if (!has(node, info.property)) {
6161
return false
6262
}
6363

64-
val = node.properties[info.property]
64+
value = node.properties[info.property]
6565

6666
// If this is a comma-separated list, and the query is contained in it, return
6767
// true.
6868
if (
69-
typeof val === 'object' &&
69+
typeof value === 'object' &&
7070
!info.commaSeparated &&
71-
val.indexOf(query.value) !== -1
71+
value.indexOf(query.value) !== -1
7272
) {
7373
return true
7474
}
7575

7676
// For all other values (including comma-separated lists), return whether this
7777
// is an exact match.
78-
return normalizeValue(val, info) === query.value
78+
return normalizeValue(value, info) === query.value
7979
}
8080

8181
// `[attr|=value]`

lib/enter-state.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -113,14 +113,14 @@ function enter(state, node) {
113113
}
114114

115115
function dirBidi(value) {
116-
var val = direction(value)
117-
return val === 'neutral' ? null : val
116+
var result = direction(value)
117+
return result === 'neutral' ? null : result
118118
}
119119

120120
function dirProperty(node) {
121-
var val = node.properties.dir
122-
val = typeof val === 'string' ? val.toLowerCase() : null
123-
return validDirections.indexOf(val) === -1 ? null : val
121+
var result = node.properties.dir
122+
result = typeof result === 'string' ? result.toLowerCase() : null
123+
return validDirections.indexOf(result) === -1 ? null : result
124124
}
125125

126126
function noop() {}

lib/nest.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,15 +41,15 @@ function topScan(query, node, index, parent, state) {
4141
}
4242

4343
function descendant(query, node, index, parent, state) {
44-
var prev = state.iterator
44+
var previous = state.iterator
4545

4646
state.iterator = iterator
4747

4848
child.apply(this, arguments)
4949

5050
function iterator() {
51-
state.iterator = prev
52-
prev.apply(this, arguments)
51+
state.iterator = previous
52+
previous.apply(this, arguments)
5353
state.iterator = iterator
5454

5555
if (state.one && state.found) {

package.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -52,16 +52,16 @@
5252
"browserify": "^16.0.0",
5353
"hastscript": "^5.0.0",
5454
"nyc": "^15.0.0",
55-
"prettier": "^1.0.0",
56-
"remark-cli": "^7.0.0",
57-
"remark-preset-wooorm": "^6.0.0",
58-
"tape": "^4.0.0",
55+
"prettier": "^2.0.0",
56+
"remark-cli": "^8.0.0",
57+
"remark-preset-wooorm": "^7.0.0",
58+
"tape": "^5.0.0",
5959
"tinyify": "^2.0.0",
6060
"unist-builder": "^2.0.0",
61-
"xo": "^0.27.0"
61+
"xo": "^0.32.0"
6262
},
6363
"scripts": {
64-
"format": "remark . -qfo && prettier --write \"**/*.js\" && xo --fix",
64+
"format": "remark . -qfo && prettier . --write && xo --fix",
6565
"build-bundle": "browserify . -s hastUtilSelect > hast-util-select.js",
6666
"build-mangle": "browserify . -s hastUtilSelect -p tinyify > hast-util-select.min.js",
6767
"build": "npm run build-bundle && npm run build-mangle",

test/all.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ var u = require('unist-builder')
55
var h = require('hastscript')
66
var selectAll = require('..').selectAll
77

8-
test('all together now', function(t) {
8+
test('all together now', function (t) {
99
t.deepEqual(
1010
selectAll(
1111
'dl > dt.foo:nth-of-type(odd)',

0 commit comments

Comments
 (0)