Convert flexdashboard `.Rmd` file to shiny `.R` code


Hey all! I'm currently trying to deploy a flexdashboard to a platform online. However, the platform doesn't seem able to render the .Rmd file and is looking for an app.R file.

Is there a way to convert my dashboard.Rmd file to an app.R file?

Essentially is there a function I can run that will read my .Rmd file and spit out the Shiny code that it actually generates?

Thank you all for your help!

And before anyone asks, is not an option due to the organization's current software.