How to remove all doctypes inside a module and module itself in frappe

I have a custom app, previously i have created two modules with some doctypes and report now I want to remove it. What is the best approach

hello @management

I think the best approach is to manually delete all related DocTypes, Reports via the UI first to ensure database cleanup, then:

  1. Remove module files/folders from your app.
  2. Update hooks.py to remove references.
  3. Run bench --site sitename migrate.

For removing app from site :

  1. bench --site sitename uninstall-app appname
  2. bench remove-app appname