Skip to content
New issue

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

binding expressions for function invocation #15

Open
cowboyd opened this issue Nov 18, 2022 · 0 comments
Open

binding expressions for function invocation #15

cowboyd opened this issue Nov 18, 2022 · 0 comments

Comments

@cowboyd
Copy link
Member

cowboyd commented Nov 18, 2022

One of the nice things about PlatformScript function invocation syntax is that we get to have "extra" keys of the invocation. For example:

$(x): "%($x.say), %({ $capitalize: $x.to })"
key1: ignored
key2: also ignored

We can use these keys as $let style binding expressions that enable you to compute subexpressions scoped to the function body.

$(x): "%($say), %($to)"
say: $x.say
to: {$capitalize: $x.to}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant