]>
git.proxmox.com Git - pve-eslint.git/blob - eslint/lib/rules/no-void.js
2 * @fileoverview Rule to disallow use of void operator.
7 //------------------------------------------------------------------------------
9 //------------------------------------------------------------------------------
16 description
: "disallow `void` operators",
18 url
: "https://eslint.org/docs/rules/no-void"
22 noVoid
: "Expected 'undefined' and instead saw 'void'."
34 additionalProperties
: false
40 const allowAsStatement
=
41 context
.options
[0] && context
.options
[0].allowAsStatement
;
43 //--------------------------------------------------------------------------
45 //--------------------------------------------------------------------------
48 'UnaryExpression[operator="void"]'(node
) {
52 node
.parent
.type
=== "ExpressionStatement"