diff --git a/README.md b/README.md index 864aa02c..f61a7ee0 100644 --- a/README.md +++ b/README.md @@ -13,9 +13,13 @@ You can extend from a configuration in order to simplify manual configuration of For more details on how to extend your configuration from a plugin configuration, please see the [ESLint plugin configuration documentation](https://eslint.org/docs/user-guide/configuring#using-the-configuration-from-a-plugin). -| | Name | Description | -| :-- | :--- | :---------- | -| ✅ | recommended | This configuration includes rules which I recommend to avoid QUnit runtime errors or incorrect behavior, some of which can be difficult to debug. Some of these rules also encourage best practices that help QUnit work better for you. You can use this configuration by extending from `"plugin:qunit/recommended"` in your configuration file. | + + +| | Name | Description | +| :- | :------------ | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| ✅ | `recommended` | This configuration includes rules which I recommend to avoid QUnit runtime errors or incorrect behavior, some of which can be difficult to debug. Some of these rules also encourage best practices that help QUnit work better for you. You can use this configuration by extending from `"plugin:qunit/recommended"` in your configuration file. | + + ## Rules diff --git a/docs/rules/no-ok-equality.md b/docs/rules/no-ok-equality.md index b926c4ed..deee0507 100644 --- a/docs/rules/no-ok-equality.md +++ b/docs/rules/no-ok-equality.md @@ -66,9 +66,13 @@ QUnit.test("Name", function (assert) { assert.ok(x instanceof Number); }); ## Options -This rule takes an optional object containing: + -* `allowGlobals` (boolean, default: true): Whether the rule should check global assertions +| Name | Description | Type | Default | +| :------------ | :----------------------------------------------- | :------ | :------ | +| `allowGlobal` | Whether the rule should check global assertions. | Boolean | `true` | + + ## When Not to Use It diff --git a/index.js b/index.js index df3664ae..411b8300 100644 --- a/index.js +++ b/index.js @@ -15,6 +15,7 @@ module.exports = { // eslint-disable-next-line sort-keys configs: { recommended: { + description: "This configuration includes rules which I recommend to avoid QUnit runtime errors or incorrect behavior, some of which can be difficult to debug. Some of these rules also encourage best practices that help QUnit work better for you. You can use this configuration by extending from `\"plugin:qunit/recommended\"` in your configuration file.", plugins: ["qunit"], rules: { "qunit/assert-args": "error", diff --git a/lib/rules/no-ok-equality.js b/lib/rules/no-ok-equality.js index fab8c2f4..c9c93fc9 100644 --- a/lib/rules/no-ok-equality.js +++ b/lib/rules/no-ok-equality.js @@ -28,7 +28,9 @@ module.exports = { type: "object", properties: { allowGlobal: { - type: "boolean" + type: "boolean", + description: "Whether the rule should check global assertions.", + default: true } }, additionalProperties: false