How can insert a varables inside code block output? #1547
Answered
by
MichaelHatherly
eggcaker
asked this question in
Questions about using Pluto
-
ex: I defined a variable in another block
if I write a markdown code block like
it's can render to
|
Beta Was this translation helpful? Give feedback.
Answered by
MichaelHatherly
Oct 8, 2021
Replies: 1 comment 1 reply
-
Interpolating into code blocks and code literals inside Markdown.parse(
"""
```java
public string userId = $userId;
```
"""
) |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
eggcaker
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Interpolating into code blocks and code literals inside
md"
strings isn't supported. This was a design choice of theMarkdown
parser itself rather than anything related toPluto
. If you're wanting to interpolate into code literals like that then you can callMarkdown.parse
on aString
where you have already interpolateduserID
: