Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork1.9k
Commitaebb187
Trailing semicolon (#2962)
* Only put trailing semicolon when merging style attributesThis is a first draft that tries to maintain the same code behaviorwithout worrying too much about the code quality* Update tests so they reflect the new code behaviorAll style attributes that received a String won't generatea trailing semicolon* Improve merge trailing semicolon codeCheck if String is not empty by checking if it its true ('' is false)Get last character of the string using slice(-1)Add semicolon if the last string character is not a semicolon* Use array style indexing instead of `.slice` to get last character1 parent8248ba8 commitaebb187
File tree
6 files changed
+15
-16
lines changed- packages
- pug-runtime
- test
- pug/test
- cases-es2015
- cases
- output-es2015
6 files changed
+15
-16
lines changedLines changed: 3 additions & 4 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
30 | 30 |
| |
31 | 31 |
| |
32 | 32 |
| |
| 33 | + | |
33 | 34 |
| |
| 35 | + | |
34 | 36 |
| |
35 | 37 |
| |
36 | 38 |
| |
| |||
109 | 111 |
| |
110 | 112 |
| |
111 | 113 |
| |
112 |
| - | |
113 |
| - | |
114 |
| - | |
115 |
| - | |
| 114 | + | |
116 | 115 |
| |
117 | 116 |
| |
118 | 117 |
| |
|
Lines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
132 | 132 |
| |
133 | 133 |
| |
134 | 134 |
| |
135 |
| - | |
| 135 | + | |
136 | 136 |
| |
137 | 137 |
| |
138 | 138 |
| |
|
Lines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1 |
| - | |
| 1 | + |
Lines changed: 3 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
7 | 7 |
| |
8 | 8 |
| |
9 | 9 |
| |
| 10 | + | |
10 | 11 |
| |
| 12 | + | |
11 | 13 |
| |
12 |
| - | |
13 |
| - | |
14 |
| - | |
| 14 | + | |
15 | 15 |
| |
16 | 16 |
| |
17 | 17 |
| |
|
Lines changed: 1 addition & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1 | 1 |
| |
2 |
| - | |
| 2 | + |
Lines changed: 6 additions & 6 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
371 | 371 |
| |
372 | 372 |
| |
373 | 373 |
| |
374 |
| - | |
375 |
| - | |
| 374 | + | |
| 375 | + | |
376 | 376 |
| |
377 | 377 |
| |
378 | 378 |
| |
| |||
389 | 389 |
| |
390 | 390 |
| |
391 | 391 |
| |
392 |
| - | |
393 |
| - | |
394 |
| - | |
395 |
| - | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
396 | 396 |
| |
397 | 397 |
| |
398 | 398 |
| |
|
0 commit comments
Comments
(0)