diff --git a/lib/get-text.js b/lib/get-text.js index b4cad15b..fc8dcb5e 100644 --- a/lib/get-text.js +++ b/lib/get-text.js @@ -283,10 +283,16 @@ export default class GetText { } else if ( property.value.type === "ArrayExpression" ) { for ( const element of property.value.elements ) { - if ( element.type !== "Literal" ) continue; - - res.tags ??= []; - res.tags.push( element.value ); + if ( element.type === "Literal" ) { + res.tags ??= []; + res.tags.push( element.value ); + } + else if ( element.type === "TemplateLiteral" ) { + if ( element.quasis.length === 1 ) { + res.tags ??= []; + res.tags.push( element.quasis.map( node => node.value.cooked ).join( "${n}" ) ); + } + } } } }