This repository has been archived by the owner on Jul 14, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Autogenerated new docs and demo at Fri May 19 2017 14:43:59
- Loading branch information
1 parent
ee72353
commit 0a65882
Showing
13 changed files
with
634 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
--- | ||
layout: post | ||
title: ESLint v4.0.0-beta.0 released | ||
tags: | ||
- release | ||
- major | ||
--- | ||
# ESLint v4.0.0-beta.0 released | ||
|
||
We just pushed ESLint v4.0.0-beta.0, which is a major release upgrade of ESLint. This release adds some new features and fixes several bugs found in the previous release. This release also has some breaking changes, so please read the following closely. | ||
|
||
|
||
|
||
|
||
## Breaking Changes | ||
|
||
|
||
* [3ec436ee](https://github.com/eslint/eslint/commit/3ec436ee) Breaking: New Linter API (fixes [#8454](https://github.com/eslint/eslint/issues/8454)) ([#8465](https://github.com/eslint/eslint/issues/8465)) (Gyandeep Singh) | ||
|
||
|
||
|
||
|
||
## Features | ||
|
||
|
||
* [2f7015b6](https://github.com/eslint/eslint/commit/2f7015b6) New: [semi-style](/docs/rules/semi-style) rule (fixes [#8169](https://github.com/eslint/eslint/issues/8169)) ([#8542](https://github.com/eslint/eslint/issues/8542)) (Toru Nagashima) | ||
* [a93a2f95](https://github.com/eslint/eslint/commit/a93a2f95) New: [padding-line-between-statements](/docs/rules/padding-line-between-statements) rule (fixes [#7356](https://github.com/eslint/eslint/issues/7356)) ([#8099](https://github.com/eslint/eslint/issues/8099)) (Toru Nagashima) | ||
* [0ef09ea0](https://github.com/eslint/eslint/commit/0ef09ea0) New: [for-direction](/docs/rules/for-direction) rule (fixes [#8387](https://github.com/eslint/eslint/issues/8387)) ([#8519](https://github.com/eslint/eslint/issues/8519)) (薛定谔的猫) | ||
* [482d5720](https://github.com/eslint/eslint/commit/482d5720) New: [switch-colon-spacing](/docs/rules/switch-colon-spacing) rule (fixes [#7981](https://github.com/eslint/eslint/issues/7981)) ([#8540](https://github.com/eslint/eslint/issues/8540)) (Toru Nagashima) | ||
|
||
|
||
|
||
|
||
## Enhancements | ||
|
||
|
||
* [3418479a](https://github.com/eslint/eslint/commit/3418479a) Update: improve [indent](/docs/rules/indent) of `flatTernaryExpressions` (fixes [#8481](https://github.com/eslint/eslint/issues/8481)) ([#8587](https://github.com/eslint/eslint/issues/8587)) (Toru Nagashima) | ||
* [268d52ef](https://github.com/eslint/eslint/commit/268d52ef) Update: Use sane defaults for JSX indentation (fixes [#8425](https://github.com/eslint/eslint/issues/8425)) ([#8593](https://github.com/eslint/eslint/issues/8593)) (Teddy Katz) | ||
* [afa35c68](https://github.com/eslint/eslint/commit/afa35c68) Update: check allman-style classes correctly in [indent](/docs/rules/indent) (fixes [#8493](https://github.com/eslint/eslint/issues/8493)) ([#8569](https://github.com/eslint/eslint/issues/8569)) (Teddy Katz) | ||
* [456f519b](https://github.com/eslint/eslint/commit/456f519b) Update: make [indent](/docs/rules/indent) MemberExpression handling more robust (fixes [#8552](https://github.com/eslint/eslint/issues/8552)) ([#8554](https://github.com/eslint/eslint/issues/8554)) (Teddy Katz) | ||
|
||
|
||
|
||
|
||
## Bug Fixes | ||
|
||
|
||
* [eb14584a](https://github.com/eslint/eslint/commit/eb14584a) Fix: [no-unneeded-ternary](/docs/rules/no-unneeded-ternary) change code behavior after fix (fixes [#8507](https://github.com/eslint/eslint/issues/8507)) ([#8624](https://github.com/eslint/eslint/issues/8624)) (Jan Peer Stöcklmair) | ||
* [3fc9653a](https://github.com/eslint/eslint/commit/3fc9653a) Fix: Call expression consistency in variable declaration (fixes [#8607](https://github.com/eslint/eslint/issues/8607)) ([#8619](https://github.com/eslint/eslint/issues/8619)) (Reyad Attiyat) | ||
* [a73e6c09](https://github.com/eslint/eslint/commit/a73e6c09) Fix: Fix failing uknown node test since [#8569](https://github.com/eslint/eslint/issues/8569) indents class bodies ([#8588](https://github.com/eslint/eslint/issues/8588)) (Reyad Attiyat) | ||
* [c6c639d6](https://github.com/eslint/eslint/commit/c6c639d6) Fix: Ignore unknown nodes for Indent rule (fixes [#8440](https://github.com/eslint/eslint/issues/8440)) ([#8504](https://github.com/eslint/eslint/issues/8504)) (Reyad Attiyat) | ||
* [df17bc87](https://github.com/eslint/eslint/commit/df17bc87) Fix: [object-shorthand](/docs/rules/object-shorthand) crash on some computed keys (fixes [#8576](https://github.com/eslint/eslint/issues/8576)) ([#8577](https://github.com/eslint/eslint/issues/8577)) (Teddy Katz) | ||
* [de0b4ad7](https://github.com/eslint/eslint/commit/de0b4ad7) Fix: Indent Ignore Variable Declaration init operator (fixes [#8546](https://github.com/eslint/eslint/issues/8546)) ([#8563](https://github.com/eslint/eslint/issues/8563)) (Reyad Attiyat) | ||
* [927ca0dc](https://github.com/eslint/eslint/commit/927ca0dc) Fix: invalid syntax from [prefer-arrow-callback](/docs/rules/prefer-arrow-callback) autofixer (fixes [#8541](https://github.com/eslint/eslint/issues/8541)) ([#8555](https://github.com/eslint/eslint/issues/8555)) (Teddy Katz) | ||
* [873310e5](https://github.com/eslint/eslint/commit/873310e5) Fix: run [no-unexpected-multiline](/docs/rules/no-unexpected-multiline) only if needed (fixes [#8550](https://github.com/eslint/eslint/issues/8550)) ([#8551](https://github.com/eslint/eslint/issues/8551)) (Ruben Bridgewater) | ||
* [833a0cad](https://github.com/eslint/eslint/commit/833a0cad) Fix: confusing RuleTester error message when options is not an array ([#8557](https://github.com/eslint/eslint/issues/8557)) (Teddy Katz) | ||
|
||
|
||
|
||
|
||
## Documentation | ||
|
||
|
||
* [5b6093ef](https://github.com/eslint/eslint/commit/5b6093ef) Docs: Remove .eslintignore reference to transpiled file filtering ([#8622](https://github.com/eslint/eslint/issues/8622)) (Alex Summer) | ||
* [11493781](https://github.com/eslint/eslint/commit/11493781) Docs: Rephrase in about section ([#8609](https://github.com/eslint/eslint/issues/8609)) (Sudarsan G P) | ||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
## Chores | ||
|
||
|
||
* [729bbcdb](https://github.com/eslint/eslint/commit/729bbcdb) Chore: Fix lgtm alerts. ([#8611](https://github.com/eslint/eslint/issues/8611)) (Max Schaefer) | ||
* [d21f5283](https://github.com/eslint/eslint/commit/d21f5283) Chore: make shelljs a devDependency instead of a dependency ([#8608](https://github.com/eslint/eslint/issues/8608)) (Teddy Katz) | ||
* [23401626](https://github.com/eslint/eslint/commit/23401626) Chore: remove strip-bom dependency (refs [#8603](https://github.com/eslint/eslint/issues/8603)) ([#8606](https://github.com/eslint/eslint/issues/8606)) (Teddy Katz) | ||
* [25db3d22](https://github.com/eslint/eslint/commit/25db3d22) Chore: avoid skipping test for env overrides (refs [#8291](https://github.com/eslint/eslint/issues/8291)) ([#8556](https://github.com/eslint/eslint/issues/8556)) (Teddy Katz) | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
--- | ||
title: for-direction - Rules | ||
layout: doc | ||
--- | ||
<!-- Note: No pull requests accepted for this file. See README.md in the root directory for details. --> | ||
|
||
# Enforce "for" loop update clause moving the counter in the right direction. (for-direction) | ||
|
||
## Rule Details | ||
|
||
A `for` loop with a stop condition that can never be reached, such as one with a counter that moves in the wrong direction, will run infinitely. While there are occasions when an infinite loop is intended, the convention is to construct such loops as `while` loops. More typically, an infinite for loop is a bug. | ||
|
||
Examples of **incorrect** code for this rule: | ||
|
||
```js | ||
/*eslint for-direction: "error"*/ | ||
for (var i = 0; i < 10; i--) { | ||
} | ||
|
||
for (var i = 10; i >= 0; i++) { | ||
} | ||
``` | ||
|
||
Examples of **correct** code for this rule: | ||
|
||
```js | ||
/*eslint for-direction: "error"*/ | ||
for (var i = 0; i < 10; i++) { | ||
} | ||
``` | ||
|
||
## Version | ||
|
||
This rule was introduced in ESLint 4.0.0-beta.0. | ||
|
||
## Resources | ||
|
||
* [Rule source](https://github.com/eslint/eslint/tree/master/lib/rules/for-direction.js) | ||
* [Documentation source](https://github.com/eslint/eslint/tree/master/docs/rules/for-direction.md) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.