How to start a coroutine from a command line script

I’m writing a command line script (not a MonoBehaviour) where I need to do some async work with a coroutine. Is there a way to start a coroutine outside of MonoBehaviour?

Nope. Coroutines are a Unity thing for MonoBehaviours.

You probably want to read up on Asynchronous Programming to approximate it with other methods.

I ended up using EditorApplication.update to marshal the event data from another thread back to main editor thread.