Use `write.asModule` in plugin.