Share feedback, ideas and get community help

Updated 6 months ago

Dollar sign is not printed in text block - ${{variable_name}}

At a glance

The post is about a user experiencing an issue where the dollar sign is not being displayed when using the syntax ${{variable_name}}. Community members suggest that this seems to be a bug, and provide several workarounds:

1. Adding a space between the $ and the variable, but this results in the space being printed as well.

2. Using a variable for the dollar sign and another variable for the value, then combining them as {{dollar}}{{value}}.

3. Modifying the regular expression used to parse the variables, as it seems to be the cause of the issue.

There is no explicitly marked answer, but the community members provide helpful suggestions and discuss potential solutions to the problem.

Useful resources
Why aren't the dollar signs being displayed in the text block when I use the following ${{variable_name}}?
Attachments
Screenshot_2024-09-06_at_9.59.33_PM.png
Screenshot_2024-09-06_at_10.00.08_PM.png
1
W
a
n
13 comments
seems like a bug
try putting a space between $ and variable
I tried that and the space is printed like $ 9.99
Yep, seems like a bug, thank you for the report
one workaround would be to use $ itself inside a variable. In that case, you could have both variables side by side without any space in between. that'd resolve this
Thanks for your suggestion.

It's seems like that would fix the empty space issue and creates another problem...

If I save a variable as
Plain Text
$9.99
rather than
Plain Text
9.99
, I won't be able to do math operations on it.
no i mean to say take a variable dollar = $ and another variable value = 9.99.
and then merge both like {{dollar}}{{value}}
this way it's working
Oh, I see what you mean now! Nice workaround πŸ‘ŒπŸ»
@Baptiste
Plain Text
// {{variable}} and ${{{variable}}}
const variableRegex = /\{\{([^{}]+)\}\}|(\$)\{\{([^{}]+)\}\}/g;

this regex seems to be causing the issue. it considers ${{var}} instead of {{var}} . What do you think would be the appropriate fix for this?
I think if we change the regex itself for getVariablesToParseInfoInText function, that way it'll be solved.
@Baptiste please lmk if anything i'm doing incorrectly here
Add a reply
Sign up and join the conversation on Discord