I'm trying to set up a string match using handlebars in SendGrid. As I understand it, you can only use the if statement with booleans so I'm trying via {{equals}} instead. This works fine but I'm then trying to inject that 'thing' into the result. The result I'm after in the below is that if the data = TEXT then the email reads "This is some TEXT"
{{#equals thing "TEXT"}}
This is some {{insert thing}}
{{/equals}}
Using {{insert thing}} outside the {{equals}} handlebar is fine but when inside it doesn't return anything. I just get "This is some"
Does anyone know if this is supported or if there is a better way?
Thanks.