String Interpolation With Quoted Strings
Last updated
Was this helpful?
Last updated
Was this helpful?
Stapling strings together with the ++
operator can be tedious and clunky. If you have string variables that you'd like to interpolate, you can piece them together much more easily using .
We can get close to a solution with the standard quoted string syntax.
This isn't quite right though. We have to take advantage of a preprocessing hook provided by . The j
hook supports unicode and allows variable interpolation.
To use this pre-processor we have to include j
in the quoted string like so {j|...|j}
.
See a .