|
urlString += `&latitude=${lat1}&longitude=${lng1}`; |
The += operator used to build strings is kind of a no-no in modern web development. It makes errors hard to debug because the string could be changed in any number of lines. It's better to turn the string-building into ES6 templates. Or assemble strings into different variables, and at the end assemble all the variables.
PlugHubs/index.js
Line 177 in d9c51ba
The
+=operator used to build strings is kind of a no-no in modern web development. It makes errors hard to debug because the string could be changed in any number of lines. It's better to turn the string-building into ES6 templates. Or assemble strings into different variables, and at the end assemble all the variables.