Home > front end >  JavaScript string concatenation and template string concatenation
JavaScript string concatenation and template string concatenation

Time:09-27

In JavaScript, single quotes, double quotes, string can parse variable
We write variables, can only display for the variable name string, does not show as a variable stored in the numerical,
Method 1, using string concatenation

Method 2, the use of the template string, can parse variable
Using the template string backquotes ` ` above 1 on the left side of the keyboard button
In the template string ` ` backquotes use ${variable} package variables, can analytical variable numerical
  • Related