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

Call functions with Bash-style arguments #85

Closed
NQNStudios opened this issue Apr 2, 2018 · 2 comments
Closed

Call functions with Bash-style arguments #85

NQNStudios opened this issue Apr 2, 2018 · 2 comments

Comments

@NQNStudios
Copy link
Collaborator

I think there should be a little bit more flexibility in calling JavaScript functions from within Markdown. My proposal is a syntax like this: {#function arg1 arg2 ...} where functions can optionally be defined with a signature like this:

function mFunc(args) where args will be an array of strings containing one token each.

@hyakugei
Copy link

Can the arguments be the output of other functions? expanded js variables?

{#function {$myVar}}

@NQNStudios
Copy link
Collaborator Author

My thinking was that they shouldn't be. Josh has said in the past that a core design principle is keeping complicated logic outside of markdown files altogether, and adding recursion to this would definitely add the temptation to be doing crazier things with macros. I'm thinking the only arguments allowed should be string or number literals.

@NQNStudios NQNStudios closed this as not planned Won't fix, can't repro, duplicate, stale Sep 22, 2024
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

2 participants