doc: fix nits in code examples of async_hooks.md
Checklist
-
documentation is changed or added -
commit message follows commit guidelines
Affected core subsystem(s)
doc, async_hooks
- Make
require()
consistent. - Add missing argument.
- Add missing
\n
in outputs. - Reduce string concatenations.
- Update outputs.
- Reword and fix a typo.