There seem to be multiple bugs that prevent the emulator from starting up in Node 18, at least one of which seems to be related to 18.16 in particular (the current LTS version).
There are several duplicate bugs filed in the firebase-tools-ui repo for that one, see
#942 (has links to at least some of the other duplicates). There seems to be a PR open to fix it, but it's been open for 10 days.
There are also ongoing issues that look like
#5309 in the firebase-tools repo, even though that one is marked as closed as of last December.
I haven't noticed any reference to those bugs in this group. Is the Firebase team aware of them? It's pretty frustrating not to be able to run the emulator. I finally got it to run tonight after like an hour of fiddling with workarounds.
Example errors:
Error: package.json in functions directory has an engines field which is unsupported. Valid choices are: {"node": 10|12|14|16}
⚠ ui: Fatal error occurred:
Emulator UI has exited with code: 1,
stopping all running emulators
i ui: Stopping Emulator UI
⚠ ui: Error stopping Emulator UI