Skip to content

Conversation

@mpkorstanje
Copy link
Contributor

@mpkorstanje mpkorstanje commented Jul 11, 2024

🤔 What's changed?

We're writing the json messages inside a <script> element. This means that the </script> element must be escaped. Or more generally, any /.

⚡️ What's your motivation?

Fixes: #311

🏷️ What kind of change is this?

  • 🐛 Bug fix (non-breaking change which fixes a defect)

♻️ Anything particular you want feedback on?

Is there a better way to do this?

📋 Checklist:

  • I agree to respect and uphold the Cucumber Community Code of Conduct
  • I've changed the behaviour of the code
    • I have added/updated tests to cover my changes.
  • My change requires a change to the documentation.
    • I have updated the documentation accordingly.
  • Users should know about my change
    • I have added an entry to the "Unreleased" section of the CHANGELOG, linking to this pull request.

@mpkorstanje mpkorstanje force-pushed the escape-json branch 2 times, most recently from 991bd30 to e9f040a Compare July 11, 2024 19:56
We're writing the json messages inside a `<script>` element. This means
that the `</script>` element must be escaped. Or more generally, any
`/`.
@mpkorstanje mpkorstanje marked this pull request as ready for review July 12, 2024 00:16
@mpkorstanje mpkorstanje merged commit 8bfb97c into main Jul 18, 2024
@mpkorstanje mpkorstanje deleted the escape-json branch July 18, 2024 11:01
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

Successfully merging this pull request may close these issues.

Html formatter breaks when step has </script> text

1 participant