observablehq / feedback

Customer submitted bugs and feature requests
42 stars 3 forks source link

Markdown bold toggle interacts in a flawed way with JavaScript's exponentiation operator #564

Open yurivish opened 1 year ago

yurivish commented 1 year ago

Describe the bug Toggling bold on interpolated code with a ** turns syntactically correct JavaScript into a syntax error

To Reproduce Steps to reproduce the behavior: https://observablehq.com/d/bbcf48b517d7a623

1. image

  1. highlight then press cmd+b or click the bold B button image

  2. evaluating the cell now shows a syntax error image

Expected behavior **{2**m}**

Desktop (please complete the following information): Chrome 112, macOS, laptop