-
-
Notifications
You must be signed in to change notification settings - Fork 928
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
Adds ignorePattern option to max-line-length #2333
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One nitpicky comment, otherwise looks good! Thanks @CAYdenberg!
lib/rules/max-line-length/README.md
Outdated
Given: | ||
|
||
```js | ||
["/^\\@import\\s+/"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think you need to escape @
, do you?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was not aware of t@ but it appears you're right.
I changed it in the tests as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Addressed in 07f4634
@davidtheclark do you think it should support support RegExp either? I've noticed some of our rule/options, which expect some kind of RegExp, aren't consistent on that matter. Some of them support only |
@hudochenkov The example (at-rule-empty-line-before) only applies to @ rules ... I think this should be more flexible since there are other places you might want it. Someone might want "/linear-gradient/" for example. |
@hudochenkov: Can you please try to rephrase this question? It's not clear to me what you're asking. Regarding the inconsistencies — yeah, there are a lot of rules :) If you would like to add regexp support to any options that only support strings, please open an issue or submit a PR — I usually can't think of a reason not to enable regexps. |
@davidtheclark sorry :) I wanted to know if |
@CAYdenberg Thanks! Changelog updated:
|
* master: (107 commits) Update jest to the latest version 🚀 (#2372) fix(package): update known-css-properties to version 0.0.7 chore(package): update eslint to version 3.16.0 Update CHANGELOG.md Add support for async rules (#2351) Prepare 7.9.0 Add a test for a parent selector in no-duplicate-selectors (#2364) Update CHANGELOG.md Add ignorePattern option to max-line-length (#2333) no-browser-hacks: link to external plugin (#2365) Update CHANGELOG.md Fix placeholder selector case (#2360) Always exclude ignored globs from globby search. (#2355) Update CHANGELOG.md Update lodash (#2353) Update CHANGELOG.md Add ignoreFontFamilyName option to font-family-no-duplicate (#2314) Tests: added tests for nested selectors in `selector-id-pattern` rule. (#2345) Fix brace position (#2347) Update CHANGELOG.md ... # Conflicts: # .gitignore
* master: (31 commits) Update stylehacks and snapshot Update jest to the latest version 🚀 (#2372) fix(package): update known-css-properties to version 0.0.7 chore(package): update eslint to version 3.16.0 Update CHANGELOG.md Add support for async rules (#2351) Prepare 7.9.0 Add a test for a parent selector in no-duplicate-selectors (#2364) Update CHANGELOG.md Add ignorePattern option to max-line-length (#2333) no-browser-hacks: link to external plugin (#2365) Update CHANGELOG.md Fix placeholder selector case (#2360) Always exclude ignored globs from globby search. (#2355) Update CHANGELOG.md Update lodash (#2353) Update CHANGELOG.md Add ignoreFontFamilyName option to font-family-no-duplicate (#2314) Tests: added tests for nested selectors in `selector-id-pattern` rule. (#2345) Fix brace position (#2347) ... # Conflicts: # CHANGELOG.md
#2219
Pretty straightforward.