Serializable coroutines for JS