doc: fix stylistic issues in api/net.md
- Change
var
toconst
in an example of server creation. - Add missing semicolons.
- Use
console
syntax highlighting instead ofjs
in thenc
command invocation example and add a shell prompt symbol to be consistent with the rest of the documentation.
Checklist
-
documentation is changed or added -
commit message follows commit guidelines
Affected core subsystem(s)
doc