I´m sure this is a very basic question, but I´m starting with MEAN stack using express-handlebars
and still launching my skills.
I´m coming from PHP world and I use to call PHP functions from insede my phtml
code, as:
<p>© 2012 - <?= date('Y') ?> by ACME LLC. All rights reserved.</p>
That would get me the current year and print the following output:
(C) 2012 - 2016by ACME LLC. All rights reserved.
I know handlebars {{ }}
would print any context variable, but don´t want to put the current year in the conetext to be printable.
I´ve seen also handlebars helpers, but I´m not sure this is the way to go.
Help appreciated.
As per my understanding you can call a function from html code but you can set helpers to run on server side as well as client side.