Use getSimulationComputeUnits() from helpers library. This is the same code, but has unit tests, we can publish updates if we need fixing, users don't need to maintain their own copy, etc.
Change language for syntax highlighting to TS - existing code was using JS for code with types.
Tweak wording slightly to emphasize using the function rather than the RPC method the function calls.
Summary of Changes