Select to view content in your preferred language

Inline code snippets

2193
7
02-22-2022 05:07 PM
Status: Closed
Labels (1)
Bud
by
Esteemed Contributor

It would be helpful if inline code snippets could be supported in ArcGIS Community posts.

Example:

Bud_0-1645578180240.png

While we can change the font of in-line text: for point in part:, it would be better if we could also change the background color to grey, etc.

That would make it a lot easier to read text that has inline code.

Thanks!

 

7 Comments
JohannesLindner
jcarlson

You can try manually changing things in the HTML source.

jcarlson_0-1645629968073.png

 

Just add "<code>" and "</code>" around your text.

What we should really be asking for is a button in the toolbar to get at this setting easily, since the setting already exists.

EDIT: Evidently, those are in the list of "invalid HTML" elements.

jcarlson_0-1645630068181.png

When I try to post with <code> tags, they get stripped out.

Bud
by

@jcarlson 

Yeah, I don't know why the <code> tags need to be stripped out.

It seems like forums from other vendors like the IBM Community forum use the same underlying 3rd party text editor that the ArcGIS community uses. But in IBM's implementation of the text editor, inline code snippets are allowed.

For example, I can enter a code snippet, and it will be highlighted in red, just like the ArcGIS Community forum. But the difference is: it won't be stripped out. The inline code snippet will show up in the final post without issue.

Bud_0-1645630660135.png

I wonder if ESRI could consider allowing inline code snippets too?

Cheers.

MichelleMathias

Thank you, our vendor is planning to deploy a newer version of the text editor later this year, and hopefully that will resolve it, but we will add it to our development backlog as well.

MichelleMathias
Status changed to: Under Review
 
Thomas_Z2

It would be nice to just have a plain text markdown editor!

At least, let the user decide if they want to use a text editor or a WYSIWYG editor. And if they do, please do not save it to HTML so everything is screwed up when editing an answer/question!

SimiBasu
Status changed to: Closed

@Bud  Thank you for your idea. We are limited to the functionality of the text editor our vendor is using. They plan to upgrade this editor (TinyMCE) next year, which might offer additional options, but for now this is not something we can change. Thanks Simi