HTML tags: PRE, KBD, and DETAILS
For easier searching later, I decided to make a brief post today just about some HTML tags that I use.
For pre-formatted text, I discovered in yesterday's post that long lines of powershell code were not wrapping to new lines. I eventually got it working as intended by formatting the HTML tags like this:
<pre style="white-space: pre-wrap;">Text goes here. blah blah blah.</pre>
I wonder, though, if I should switch to monospace font for computer code? In the past, there was the TT (teletype) tag, but apparently that's another technology that has been deprecated. Here's an example of the new KBD (keyboard) code instead. I don't know. It looks exactly the same to me, except for the change in vertical spacing. I'll stick with PRE instead, I guess. I could use KBD inline within a paragraph if needed.
<kbd>this is a test. blah blah blah.</kbd>
Far more frequently, however, I use the HTML tag to display a little sideways-arrow which users need to click to "open up" a section of text. Using this tag liberally helps keep long posts from flooding other peoples' blog feeds. Readers can choose whether or not to read the long diatribes (or see the large pictures) in the main part of the blog post. Here is the code I use to accomplish that feat:
<details> <summary>Click the arrow to read the blah blah blah...</summary> All of the usual blog content goes here. </details>
There. Now I can find these tag details again when I click the HTML tag on my blog. Bread crumbs to help a failing memory.

