Hiding a block of text behind a click does not need a script or a library. HTML has an element for it, and it works with the keyboard and screen readers.
<details>
<summary>Show the full command</summary>
<p>Hidden until someone clicks.</p>
</details>
The summary is the clickable line. Add the open attribute to start with the block expanded. In recent browsers you can give several details elements the same name attribute, and then opening one closes the others, which makes it an accordion.
Caveat: text inside a closed details is not shown, and browser support for the name grouping is newer than for the element itself. Check it if you need older browsers.
Further reading: MDN: details