Skip to content

Commit fb958fd

Browse files
committed
Fixing the quote-props rule
1 parent a775cbb commit fb958fd

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

packages/eslint-config-transit/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ module.exports = {
1212
'no-use-before-define': 'off',
1313
'radix': 'off',
1414
'max-len': ['error', 120, 2],
15-
'quote-props': ['error', 'consistent-as-needed'],
15+
'quote-props': ['error', 'consistent'],
1616
'no-restricted-syntax': [
1717
'error',
1818
'ForInStatement',

packages/eslint-config-transit/test/eslint-config-transit-test.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,16 +24,16 @@ function functionDefinedBeforeUse() {
2424
// Quotes in object properties
2525
// If one property needs quotes, then we'll require quotes on any properties for the same object.
2626
const obj = {
27-
'foo word': 'bar',
28-
'other foo': 'bar2',
29-
'foo': 'bar',
27+
fooword: 'bar',
28+
otherfoo: 'bar2',
29+
foo: 'bar',
3030
};
3131

3232
// If none of them require quotes, then quotes are disallowed.
3333
const anotherObject = Object.assign({}, obj, {
34-
foo: 'bar',
35-
foo2: 'bar2',
36-
foo3: 'bar3',
34+
'foo': 'bar',
35+
'foo2': 'bar2',
36+
'foo 3': 'bar3',
3737
});
3838

3939
return anotherObject;

0 commit comments

Comments
 (0)