Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Server UI: Code snippets are being mangled by <em> italic emphasize replacement. #7023

Open
jboero opened this issue May 1, 2024 · 0 comments

Comments

@jboero
Copy link
Contributor

jboero commented May 1, 2024

.replace(/_(.*?)_(?=([^`]*`[^`]*`)*[^`]*$)/g, '<em>$1</em>')

I've been having a headache reformatting code samples in the UI as it keeps replacing underscores with italic <em> tags. Can we either add this as an option or adjust the regex to avoid ```code blocks?

In this case "createcommandqueue" should be create_command_queue and must be fixed before being used in code:
image

@jboero jboero changed the title Code snippets are being mangled by <em> italic emphasize replacement. Server UI: Code snippets are being mangled by <em> italic emphasize replacement. May 1, 2024
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

No branches or pull requests

1 participant