Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docs: Describe options in rule under Strict Mode #6312

Merged
merged 1 commit into from Jun 6, 2016
Merged

Conversation

pedrottimark
Copy link
Member

The only rule under Strict Mode

  • Make description in h1 consistent with rules index page, not even the first word is capitalized. That is because will soon change the format to match the rules index page (that is, rule-id: rule description).
  • Make first sentence under Rule Details consistent with description.
  • Add “this rule with” to example sentences.
  • Describe options according to patterns in guidelines.

Additional changes:

  • Display (removed) X icon at the left of the sentence for the earlier default option. What do you think?
  • Moved the "never" option to be the last active option, so it does not separate "global" and "function" from "safe" Hint: The diff gets confusing after safe. At that point, you might click View and compare the markdown view to the Web site: http://eslint.org/docs/rules/strict

@eslintbot
Copy link

LGTM

@eslintbot
Copy link

LGTM


A strict mode directive at the beginning of a script or function body enables strict mode semantics.
A strict mode directive is a `"use strict"` literal string expression at the beginning of a script or function body. It enables strict mode semantics.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can omit "string expression" in this description.

@eslintbot
Copy link

LGTM

1 similar comment
@eslintbot
Copy link

LGTM


All strict mode directives are flagged as unnecessary if ECMAScript modules or implied strict mode are enabled (see [Specifying Parser Options](../user-guide/configuring#specifying-parser-options)). This behaviour does not depend on the rule options, but can be silenced by disabling this rule.
* `"safe"` (default) corresponds either of the following options:
* `"global"` if ESLint considers a file to be a **Node.js** or **CommonJS** module
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We probably just want to say "CommonJS" because Node.js will support ES modules within the next year

@eslintbot
Copy link

LGTM

@nzakas
Copy link
Member

nzakas commented Jun 6, 2016

Lgtm

@nzakas nzakas merged commit 2d4efbe into master Jun 6, 2016
@pedrottimark pedrottimark deleted the docs-strict-mode branch June 6, 2016 15:56
@eslint-deprecated eslint-deprecated bot locked and limited conversation to collaborators Feb 6, 2018
@eslint-deprecated eslint-deprecated bot added the archived due to age This issue has been archived; please open a new issue for any further discussion label Feb 6, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
archived due to age This issue has been archived; please open a new issue for any further discussion
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants