| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 7f55f98 commit e41344f
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -26,6 +26,11 @@ module.exports = { | |||
| 26 | 26 | if (!isArrowFunctionWithTemplateLiteral(msg)) | |
| 27 | 27 | return; | |
| 28 | 28 | ||
| 29 | + // Checks to see if order of arguments to function is the same as the | ||
| 30 | + // order of them being concatenated in the template string. The idea is | ||
| 31 | + // that if both match, then you can use `util.format`-style args. | ||
| 32 | + // Would pass rule: (a, b) => `${b}${a}`. | ||
| 33 | + // Would fail rule: (a, b) => `${a}${b}`, and needs to be rewritten. | ||
| 29 | 34 | const { expressions } = msg.body; | |
| 30 | 35 | const hasSequentialParams = msg.params.every((param, index) => { | |
| 31 | 36 | const expr = expressions[index]; | |
| Back | FazBrowse Home | New Git URL |
0 commit comments