Here are a few of my hacky, completely unsupported asynchronous scripts for drawing things without crashing my server. Did I mention they are unsupported? The WorldEdit devs DEFINITELY do not support this or any asynchronous block editing, in any way, shape, or form. The main treat is spiral_sealed.js, which creates a cone-shaped spiral. Right now it's a mess, but you can understand how to use it if you read the script. I have a bunch of examples written down inside. If you have any other ideas for asynchronous scripts, create an issue and I'll see if I can't create them.
Setting up CraftScripts is described in the WorldEdit documentation: https://worldedit.enginehub.org/en/latest/usage/other/craftscripts/