Is it possible to use {{@type}}
in a way without deactivating @data
in Handlebars?
Dataexample:
var data = {"@type" : "test"}
Is there an escape such as {{\\@type}}
or something similar?
Found a solution. Just using helpers:
Handlebars.registerHelper("escape", function(obj, name) {
return obj[name];
});
And then just use
{{escape this "@type"}}
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.