Skip to content
This repository was archived by the owner on Mar 23, 2024. It is now read-only.

Commit 0526e68

Browse files
committed
disallowSpacesInsideParentheses: fix es6 template literal token issues
Fixes #748
1 parent e300107 commit 0526e68

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070
"cli-table": "~0.3.1",
7171
"commander": "~2.6.0",
7272
"esprima": "^1.2.5",
73-
"esprima-harmony-jscs": "1.1.0-tolerate-import",
73+
"esprima-harmony-jscs": "1.1.0-templates",
7474
"estraverse": "^1.9.3",
7575
"exit": "~0.1.2",
7676
"glob": "^5.0.1",

test/specs/rules/disallow-spaces-inside-parentheses.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,10 @@ describe('rules/disallow-spaces-inside-parentheses', function() {
9797
it('should not report with no spaces in an export default statement', function() {
9898
assert(checker.checkString('export default function() {}').isEmpty());
9999
});
100+
101+
it('should not report with no spaces in an interpolated template string', function() {
102+
assert(checker.checkString('throw new Error(`foo ${"bar"}`);').isEmpty());
103+
});
100104
});
101105

102106
describe('"only" option', function() {

0 commit comments

Comments
 (0)