# StringTemplate does not respect NumberFormat

I am trying to write Latex report generator for my standard data analysis. But there is an issue with formatting numbers I can not get around. I would like to make use of my own NumberFormat and StringTemplatess but the last reformats the numbers. Here is an example:

n = QuantityMagnitude@UnitConvert@Quantity["PlanckConstant"]


6.626070*10^-34

ScientificForm[n, 3,
ExponentFunction -> (If[-10 < # < 10, Null, #] &),
NumberFormat -> (If[#3 != "", Row[{#1, "e", #3}], #1] &)]


6.63e-34

StringTemplate["A: "]@%


A: 0.00000000000000000000000000000000066260696

Is there a way to make StringTemplate output the numbers in a format I have specified? I guess the problem might have something to do with underlying TextString.

The default InsertionFunction for StringTemplate is TextString; use ToString instead:
SetOptions[StringTemplate, InsertionFunction -> ToString]

StringTemplate["A: "]@ToString@%

"A: 6.63e-34"