We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Is it possible to have a 'variable' type helper?
With Handlebars (which a lot of my old stuff uses) I have a helper called 'var', this helper is defined as
Handlebars.registerHelper('var', function(name, value, context) { this[name] = value; });
Then in code I would do
{{var myVariable "Test"}}
Then I could access that variable by doing
{{myVariable}}
Is there any way to do something similar with Template7?
The text was updated successfully, but these errors were encountered:
Actually, looking at it further, it does work, but not with anything more complex.
So as above it works fine, but if I do
{{ var "myVariable" ( myHelper "test" ) }}
Where 'myHelper' might be defined as
Template7.registerHelper('myHelper', function(val) { return val; });
And then I later on call that variable by doing
Template7 comes back with a
Uncaught SyntaxError: Unexpected token ( at Template7Class.compile (template7.js:600) at Function.Template7.compile (template7.js:649)
This is using Template7 1.4.1, i've also tried 1.3.6 (which is what I was using earlier)
Sorry, something went wrong.
No branches or pull requests
Is it possible to have a 'variable' type helper?
With Handlebars (which a lot of my old stuff uses) I have a helper called 'var', this helper is defined as
Then in code I would do
Then I could access that variable by doing
Is there any way to do something similar with Template7?
The text was updated successfully, but these errors were encountered: