Граф коммитов

275 Коммитов

Автор SHA1 Сообщение Дата
Bernd Kiefer 0b389f96d0
Update README.md 2020-12-10 09:13:39 +01:00
Bernd Kiefer bffcdd8a7f
Update README.md 2020-12-10 09:09:44 +01:00
Noam Yogev 8f86920e4f feat(rule): Add new rule - react-a11y-media-captions (#850)
* add new reactA11yMediaCaptionsRule

* add react-a11y-media-caption to readme

* add unit tests
fix behavior of validateMediaType

* fix according to comments
add unit tests

* modify get JsxExpression
text to look only for string literals

* modify to check string literal inside JsxExpression
add spread attributes logic to track elements

* replace getAttributeText with getStringLiteral

* add uni test to indicate no variable as expression

* git l
2019-07-29 12:33:27 +03:00
Andrii Dieiev 6530da9d93
Update CHANGELOG.md and package.json for 6.2.0-beta (#865) 2019-05-19 02:23:45 +03:00
Andrii Dieiev f85d5f6dbc
Improve prefer-array-literal rule (#862)
* Use only tslint --test for prefer-array-literal rule

* Restrict only global objects with Array (fixes #856)

* Add allow-single-argument option and check argument types (fixes #822)

* Update docs and metadata for prefer-array-literal rule

* Apply suggestions related to wording in README.md

Co-Authored-By: Josh Goldberg <joshuakgoldberg@outlook.com>

* Change new option name to allow-size-argument

* Use Set for restricted namespaces. Add `self` to restrictions

* Fix error message for incorrect size argument

* Handle array spread in argument position

* Drop node text from all error messages

* Handle potential exceptions from TS

* Add comment about additional check for SpreadElement
2019-05-18 02:47:02 +03:00
Andrew b8194214f6 Added new `detect-child-process` rule (#252) (#855)
* Added new `detect-child-process` rule (#252)

* Minor docs changes (#252)
2019-04-24 08:19:55 -04:00
Liz f3229e0583 Mouse events have key events rule (#849)
* mouse event has key event rule

* add readme bit

* remove conflicting file

* @next version, add csv

* use set for faster look up, add more test cases

* declare function outside cb

* fix invalid tsx

* ignore spread attributes
2019-04-22 09:24:54 -04:00
apawast fc41f7cc64 Azure pipelines (#838)
* Set up CI with Azure Pipelines

* Setting up CI with Azure Pipelines

* Added Azure Pipelines status badge
2019-03-15 21:26:02 -04:00
Arthur Denner fbdc415878 Update w3 reference in the react-a11y-role rule (#847)
* Update w3 reference in the react-a11y-role rule

* Update tests related to the react-a11y-role rule
2019-03-13 19:10:52 +02:00
Arthur Denner a6754593a1 Add Prettier badge (#848)
* Add Prettier badge

* Remove flat square style to match other icons

Co-Authored-By: arthurdenner <arthurdenner7@gmail.com>
2019-03-13 17:27:41 +02:00
Sangwon Kim 915ecc0fa3 docs(readme): Fix typo (#835) 2019-02-26 16:06:32 +02:00
Olly Levett c3b293ec06 update readme links to config files (#834) 2019-02-26 16:04:38 +02:00
Josh Goldberg 17080557c1
Revamped configs into 'core', 'latest', and (legacy) 'recommended' (#809)
* Revamped configs into 'core', 'latest', and (legacy) 'recommended'

Those three config files now exist as `.json` under `/configs`; they're copied to `dist/build/configs`. `recommended.json` becomes `tslint.json` as well.

* Normalized trailing commas; added back .gitignore fields

* Moved void-zero to latest.json

* Moved to exporting root-level configs

* Switched to auto-generating latest.json

* Aligned naming with TSLint's recommended -> latest

* Update ExtendedMetadata.ts
2019-02-19 08:03:56 -05:00
Andrii Dieiev 66b9c68a98 Move Wiki pages to docs foldes (fixes #808) (#818)
* Replace Release Notes with info about CHANGELOG.md and Releases

* Replace Release Notes with links to CHANGELOG.md and Releases

* Updated Releases (markdown)

* Revert "Updated Releases (markdown)"

This reverts commit b9214fd89cc3cd2238a4f43c3c4bf7ac3c2cc7e9.

* Add instruction to replace @next placeholder

* Move Wiki files to docs folder (fixes #808)

* Apply Prettier formatter to docs

* Update link to Releases doc

* Replace Markdown table format with HTML table

* Add links from removed Releases page to README.md
2019-02-17 15:04:13 -05:00
Andrii Dieiev f70d669310 Strict order of rules in README.md (#817)
* Validate order of rules in README.md (fixes #816)

* Fix rules order in README.md

* create-rule task also updates README (fixed #816)

* Update CONTRIBUTING.md with detais about README.md actions (fixes #648)
2019-02-10 17:14:15 -05:00
Sean Healy f1a62ab1a7 `react-this-binding-issue` typo (#797) 2019-01-26 09:13:19 -05:00
Noam Yogev f67d898d74 Implement react-a11y-iframes rule (#692)
* implement reactA11yIFramesRule
add unit tests

* generate README and tslint.json

* generate README and tslint.json

* Rename reactA11yIFramesRule.ts to reactA11yIframesRule.ts

* Rename reactA11yIFramesRuleTests.ts to reactA11yIframesRuleTests.ts

* add call to super, fix README.md, lowercase tsUtils

* add tslint tests
fix build error (String -> string)

* update tslint-warnings after npm install

* remove mocha test
add comma to rule description
fix function names in test.tsx.lint

* refactor reactA11yIframsRule to use walk function
add unit tests for class and function rule enforcement

* remove resetting previousTiltles when JsxFragment is enountered

* add some test cases
2019-01-19 15:52:14 -05:00
Liz 07567bf697 void-0-rule (#770)
* add rule and test

* feeback - simplify rule, update to new test format, fix descriptions

* feedback - fix typo, version, rationale on one line

* feedback -add fix for rule

* Remove extra line
2019-01-10 20:51:05 +02:00
Josh Goldberg 168d8741f7
Deprecated now-duplicate rules from TSLint 5.12.0 (bumped devDependency to 5.12.0) (#686)
* Deprecated now-duplicate rules from TSLint 5.12.0 (bumped devDependency to 5.12.0)

Fixes #684. Fixes #685.

* Added missing deprecation notices in README.md

* Update noUnnecessaryBindRule.ts

* Corrected changes in package-lock.json and metadata

* Fixed recommended ruleset and tslint warnings

* Removed breaking rule changes

* Fixed recommendation typos

* Updated metadata files

* Reverted react-a11y-accessible-headings line
2018-12-27 10:08:28 -05:00
Noam Yogev 302c65f608 #274 Implement react-a11y-accessible-headings (#651)
* implement react-a11y-accessible-headings

* fix tslint.json after merge

* add an ability to distinct unbinded/binded jsxElements.
fix review comments
add unit tests

* re-implement rule, remove unwanted private members,
re-write unit tests

* remove elements ordering enforcement,
add default heading length,
fix rule description and options description

add unit tests for react components and functions,
add unit tests for nested heading elements, spans and expressions
2018-12-17 15:35:54 -08:00
Josh Goldberg 112ca00cec
Deprecated no-reserved-keywords (#674)
* Deprecated no-reserved-keywords

* Fixed silly copy & paste errors

* Fixed recommendation to be false

* Undid changes to tslint-warnings.csv
2018-12-14 09:09:59 -08:00
Christian Bewernitz 2ac8e35649 react-a11y-no-onchange rationale (#668)
* Add reference for react-a11y-no-onchange

to README.md and metadata.rationale

* README: add missing closing li tag

* README: put use-simple-attribute into alphabetical position

* docs(react-a11y-anchors): add references to metadata.rational

* docs(react-a11y-event-has-role): add references to metadata.rational

* docs(react-a11y-img-has-alt): add references to metadata.rational

* docs(react-a11y-input-elements): add references to metadata.rational

* docs(react-a11y-lang): add references to metadata.rational

* docs(react-a11y-required): add references to metadata.rational

* docs(react-a11y-role-has-required-aria-props): add references to metadata.rational

* docs(react-a11y-no-positive): add references to metadata.rational

* docs(react-a11y-titles): add references to metadata.rational

* docs(react-a11y-role-supports-aria-props): add references to metadata.rational

- sync description with README in markdown format

* docs(react-a11y-role): add references to metadata.rational

- sync description with README in markdown format
2018-12-10 22:01:38 -08:00
Noam Yogev 4b911106ba #147 implement use-simple-attribute (#628)
* implement use-simple-attribute

* fix typo in useSimpleAttributeRule
reorder use-simple-attribute in tslint.json

* add rationale to useSimpleAttributeRule

* Merge branch master; rename to plural rule

* Added description to README.md
2018-11-09 12:45:02 -05:00
Josh Goldberg 02b8bc80c8
Prepared 6.0.0-beta release (#647)
* Prepared 6.0.0-beta0 release

* Removed weird README.md garbage

* Switched to beta, not beta0, beta.0, or beta.1

* Removed version number
2018-11-06 15:11:49 -05:00
Josh Goldberg c44796d777
Removed unnecessary export-name doc line in README.md (#643)
Fixes #635
2018-11-05 17:44:07 -06:00
Josh Goldberg 87c742f563
Updated Configuration in README.md to refer to tslint.json (#637)
* Updated Configuration in README.md to refer to tslint.json

No need to have it mention Grunt specifically, since `tslint.json` is the standard for configuring lint settings.

Fixes #627.

* Nit: option
2018-11-05 11:47:08 -06:00
Josh Goldberg 0adf1e67a4
Removed mentions of now-deprecated formatters from README.md (#638)
* Removed mentions of now-deprecated formatters from README.md

Continues #577.

* Removed validation build step
2018-11-05 10:55:50 -06:00
Josh Goldberg 0d2b6780cc
Removed references to npm-*.*.* and releases branches from docs (#626)
I'll also update the Releases wiki page to no longer suggest them.

Fixes #610
2018-11-05 01:08:11 -06:00
Saugat Acharya 9084d549f5 Use prettier to format source files (#623)
* Add prettier, prettierrc and prettierignore

* Add tslint-config-prettier to avoid tslint and prettier conflicts

* First prettier run

* Prettify json files

* Ignore package.json and package-lock.json

* Prettier json files

* Use single quotes

* Revert to single quotes

* Use 4 spaces when creating JSON files

* Remove TODO comments

* Bring back TODO comments

* Add tslint:check as part of test script

* Remove conflicting rules from tslint.json as reported by tslint-config-prettier

* Use exact version for prettier

* Fix tests

* tslint-disable for variable-name

* Add no-unnecessary-semicolons to disabled rules

* Disable arrow-return-shorthand

* Make comment spacing consistent

* Update recommendations

* Single space before and after curly parens

* Generate recommended_ruleset with single quotes

* Single quote 'rule' key

* Grammatical fix

* Generate recommended ruleset

* Ignore recommended_ruleset.js

* Format markdown files using prettier

* Format *.md files

* Remove new line

* Add tslint:check before linting

* Update .prettierignore

* Add husky and lint-staged

* Run prettier on pre-commit

* Add prettier-vscode as a recommendation

* Escape asterisk

* Remove extra space

* Remove unwanted string concatenations
2018-11-05 00:56:31 -06:00
Josh Goldberg 8ffadb7c0e
Separated development docs into a CONTRIBUTING.md (#617)
* Separated development docs into a CONTRIBUTING.md

* Feedback
2018-11-02 15:43:19 -07:00
Andrii Dieiev d3e3ec4e8f Removed `npm start` "dependency" on `npm test` (#619) 2018-10-31 09:56:14 -07:00
Andrii Dieiev ea3f12bb06 Add watcher that will run tests and lint (#616)
* Fix possible lint errors

* Implement watcher that will run tests and lint.
2018-10-30 15:15:27 -04:00
Josh Goldberg b1cf2ebec1
Lowered documented version to current (5.2.1) (#607) 2018-10-29 11:32:25 -04:00
Saugat Acharya 23927d5fa2 Fix typo (#599)
```
- doccumentation
+ documentation
```
2018-10-29 10:45:26 -04:00
Júlio César Neves dad01c21ea Fixes #280: Implements acessibility rule for required input elements (react-a11y-required) (#598) 2018-10-27 22:06:19 -04:00
Andrii Dieiev bf1c20d296 Migrate from Grunt to npm scripts (#584)
* Fix lint errors

* Add regular Grunt tasks to npm scripts

* Add example for testing rules with tslint --test

* Migrate custom grunt tasks to node scripts

* Add create rule task

* Remove Grunt and related packages

* Use ES2015 template literals for build tasks

* Update VS Code debug tasks

* Add simler watcher tasks and update README with relevant info

* Remove unnecessary Grunt install step on CI

* Fix forrmatting and typos in README.md

* Sorted most scripts alphabeticallt. Renamed ts > tsc

* Split common.js. Use destructuring for requires.

* Remove unnecessary test-data compilation

* Return colorful outpur for errors. Format template literals
2018-10-27 20:29:21 -04:00
Saugat Acharya 32e4b23018 Add CODE_OF_CONDUCT.md (#597)
* Add code of conduct file

* Link to code of conduct
2018-10-27 14:14:00 -04:00
Zack 8f85ae630c clarify import-name rule (#593) 2018-10-27 12:51:12 -04:00
Josh Goldberg 9e3ca54705
Converted the giant rules list in README.md to a table (#578)
...so much manual typing...

Fixes #573.
2018-10-26 08:56:17 -04:00
Eric Liprandi 30aca14365 add clarification to import-name rule (#590)
show example for more complex package name, including snake case.
2018-10-25 18:38:55 -04:00
Evan SUAU 9180e3249d Fix #571: Avoid redundant rel values in react-anchor-blank-noopener (#574)
* Fix Microsoft/tslint-microsoft-contrib#571: avoid redundant rel attribute

* Microsoft/tslint-microsoft-contrib#574 Add option to force redundancy

* Fix Microsoft/tslint-microsoft-contrib#571: avoid redundant rel attribute

* Microsoft/tslint-microsoft-contrib#574 Add option to force redundancy

* Microsoft/tslint-microsoft-contrib#574 Update 'react-anchor-blank-noopener' doc to introduce option
2018-10-24 21:50:09 -04:00
Josh Goldberg 8d3988af5b
Finished removing unecessary (placating missing-jsdoc) JSDocs (#562)
* Marked missing-jsdoc as deprecated

Continues #400.

* Finished removing unecessary (placating missing-jsdoc) JSDocs

Fixes #557

* Added recommended_ruleset.js removal

* Really disabled missing-jsdoc

* Yup, re-ran auto-updating tasks locally

* Fixed informativeDocsRule post-merge
2018-10-23 13:58:47 +00:00
Josh Goldberg 0feea6da55
Added an InformativeDocsRule (#555)
* Added an InformativeDocsRule

For any JSDoc comment on something with a name, if the comment only rephrases the name, this complains. Takes in configurable word aliases and a list of "useless" words that don't add to comments. I expect we'll slowly find more words to add to those defaults.

Fixes #457.

* Merge branch 'master'

* Fixed a couple of lint complaints

* Added README.md comments

* Correctly added metadata for rule

* Added auto-generated tslint-warnings.csv
2018-10-23 11:00:29 +00:00
liajoy 173665137e Fix typo in README (#572) 2018-10-23 10:35:31 +00:00
br1anchen 894dc6b781 Fix #275 Add new rule for accessible input elements (#547)
* Add new rule of react-a11y-input-elements

* Update README.md and build new rule

* Use getJsxAttributesFromJsxElement only for input elements

* Revert tslint.json formator changes

* Fix missing revert tslint changes

* Update rule and tests with latest master changes
2018-10-18 09:34:55 -04:00
Sahal Saad 43b6b3ced6 #278 Implement react-a11y-no-onchange. (#543)
* #278 Implement react-a11y-no-onchange.

* Fix description & options description.

* Remove redundant accessibility.

* Update csv.

* Fix failing test.
2018-10-16 07:03:16 -04:00
Sangeet Kumar Mishra 0a1fdf0cc9 Update README.md (#548)
Double comparative
2018-10-14 16:44:25 -07:00
Nishchal Gautam 95d46933a2 feat(ReactThisBindingIssueRule): allow decorators to bind (#534)
* feat(ReactThisBindingIssueRule): allow decorators to bind

* refactor(ReactThisBindingIssue): make a method pure

* refactor(ReactThisBindingIssue): use Array.some instead of Array.find

* refactor(ReactThisBindingRule): change schema

* refactor(ReactThisBindingRule): validate config

* refactor(ReactThisBindingRule): refactor test data, more readable array check

* test(ReactThisBindingIssue): fix test data

* fix(ReactThisBindingIssue): fix check for array
2018-10-14 16:34:15 -07:00
Mohit gauniyal 7e87ab2475 Update README.md (#536)
Fixed small typos.
2018-10-09 10:28:17 -07:00
Ramya Praneetha ef2d477e82 Fix #531: export-name should be case-insensitive by default (#532)
* Fix #531: export-name should be case-insensitive by default

* Removed package-lock.json

* Modified tests

* Missed failures

* Revert "Removed package-lock.json"

This reverts commit 39c2400bfe.

* Reverted all changes to package-lock.json
2018-10-09 09:56:18 -07:00