Suggestion: use default prettier settings
I noticed the Token Extension examples look odd and thought there wasn't any linter set up, and then I saw https://github.com/solana-labs/solana-program-library/pull/7115.
Suggestion: use two spaces per prettier defaults, StandardJS, node style guide, idiomatic JS, AirBnB style guide, MDN, Google Style guide, codepen, and jsfiddle.
Not my own personal preference, but if you want people to use your examples, it's better to fit in.
PRs welcome! Can't say for sure we'll use all of them, so maybe best to do one at a time. Regardless happy to consider better formatting.
This is our Solana-wide Prettier config. I hate it too, but I didn't get here early enough to have a say.
See also https://github.com/solana-labs/eslint-config-solana.
In any case, your suggestions belong on the https://github.com/solana-labs/prettier-config-solana repo.