String Interpolation
Symbol: `
Translated to JavaScript template strings
It takes 1+ parameters.
Each parameter is a string with ${n}
symbols where n is an integer and substitution parameters.
Substitution parameter can be either value or function.
Example:
This code will print:
You can also pass the special interpolation function as the first parameter. E.g., usage of styled.div
from styled-components
: