new-cap's capIsNewExceptions false warning
See original GitHub issueI’m using 0.16.2. This code:
'use strict';
var Immutable = require('immutable');
var foo = Immutable.List();
triggers a new-cap
warning for me, A function with a name starting with an uppercase letter should only be used as a constructor
, even though I have an exception set:
"new-cap": [2, {
"capIsNewExceptions": ["Immutable"]
}]
Thank you For reference: http://facebook.github.io/immutable-js/
Issue Analytics
- State:
- Created 9 years ago
- Reactions:2
- Comments:10 (4 by maintainers)
Top Results From Across the Web
new-cap - ESLint - Pluggable JavaScript Linter
"capIsNew": false allows uppercase-started functions to be called without new operators. "newIsCapExceptions" allows specified lowercase-started function names ...
Read more >ESLint: How to set "new-cap" rule's "capIsNewExceptions ...
1 — makes it a warning, 2 — makes it an error. I'm too lazy to check, but I assume that the rest...
Read more >https://itacademy.mu/wp-content/plugins/svg-suppor...
... "optionString" : "'never', {'singleValue': false, 'objectsInArrays': false, 'arraysInArrays': false}" }, "array-callback-return" : { "active" : 0, ...
Read more >config.codekit3
... "ft" : 4, "ma" : 0, "oA" : 1, "oAP" : "\/scss\/bootstrap\/mixins\/_alert.css", ... {'singleValue': false, 'objectsInArrays': false, 'arraysInArrays': ...
Read more >https://www.cwc.com/live/careers/config.codekit3
... "dJ": 0, "ft": 1, "ie": 1, "iI": 0, "ma": 1, "oA": 1, "oAP": "\/Users\/pwong\/Documents\/_columbus\/cwc.com\/dev\/template\/bootstrap\/css\/alerts.css", ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This exception is working for Immutable:
PS: About immutable new-cap convention: https://github.com/facebook/immutable-js/issues/10
It seems like #2025 is the real issue here, so closing.