Implicitly escaped $ (or not) in quasis?

gaz Heyes gazheyes at
Wed Jun 27 11:38:59 PDT 2012

On 27 June 2012 15:59, Allen Wirfs-Brock <allen at> wrote:

> var messageWithMSGSub =  Msg`${USER_INPUT}`;  //The value of
> messageWithMsgSub is the result of calling Msg.
> Here, Msg, is a application or library provided quasi substitution handler
> function. Think about  it as the DSL compiler. In this case Msg might be
> designed to do an explicit eval of the the substitution text containing the
> attach code.  However, that fact that Msg evals some of its inputs really
> should be documented as part of the its contract.  It essentially is just
> like any other function you might call and pass a string to as an argument.
>  If you don't know or don't trust the function to not do an eval of its
> parameters then you better not pass any strings into it that originated
> from untrusted sources.

Ah sorry I misunderstood the syntax, I've also tried the demo but it isn't
clear to me how placeholders are assigned. Please could someone explain how
to pass the correct variable to a placeholder?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the es-discuss mailing list