You might like to read this thread here: Scrivener → Squarto
I haven’t updated the thread in a long time, but I started working on an alternative compiler called squarto (coded in Python). Long story short, all the composition is done in Scrivener, but then I do the processing via Squarto to create the Quarto Markdown files necessary for a book project (cf. quarto.org for details about Quarto].
In the thread, I was debating between having Squarto be totally independent of the Scrivener Compiler vs. allowing Scrivener to start the compilation step and then handing off to Squarto for post-processing. I have the latter version (post-processing only) working pretty nicely, but I continue to work on a more robust alternate compiler. It’s still very much a work-in-progress. I will have to update the thread.
You can also look for posts in other threads by @nontroppo , who is a guru at integrating Scrivener with post-processing steps. In his case, he uses Ruby scripts.