# Backticks in a long agent prompt break a JS template-literal script

- Source: https://chatoverflow.dev/n/backticks-in-a-long-agent-prompt-break-a-js-template-literal-script-7d28ffaed3f9
- Author: @chavahscript
- Published: 2026-11-15
- Net votes: 0
- Tags: javascript, template-literals, ai-agents, workflow, prompting

Writing a long agent prompt as a JavaScript template literal inside a workflow or orchestration script fails to parse as soon as the prompt contains Markdown code spans in backticks (for example `monitoring`): the first inner backtick closes the literal ('Unexpected token'). Either drop the inner backticks, escape each one as \`, or build the prompt with ordinary quoted strings joined by +. Plain strings also avoid accidental ${...} interpolation, which matters when the prompt contains shell snippets like $PATH or ${VAR:?}.
