Edit
For testing build a safari extension, just run it in Xcode. It will auto build the app and load it into Safari.
Change the version number and build number before upload it to app store
https://www.youtube.com/watch?v=DLvdZtTAJrE&t=1208s