iOS 8 Remove today extension

2019-04-09 19:59发布

问题:

I created a today extension coded in Objective c and I have decided that I do not want it in my app. I removed the scheme, the target and all the files that were associated with it, yet it remained in my notification center. I deleted the app and it was no longer in the notification center, then when I ran the app again it was back. Im afraid that when I submit the app there will be an empty widget as an option to add to notification center. Does anybody know how I can completely delete the extension from the app? Thanks!

回答1:

I simply did a product clean.

Just press command+shift+k

Now build and run and you should be all good!



回答2:

I know this is a little old, but recently I've had a similar problem with WatchKit extension, which kept popping on my Watch when I installed the app on iPhone. In my case it was due to the DerivedData folder:

In Xcode open Preferences->Locations and go to the DerivedData folder and delete everything.

I have also cleaned the project (cmd+shift+k) but I'm not sure if this was necessary.

Also if you encounter this problem it is always worth to check the Target->Build Phases's Target Dependencies & Embed App Extensions shouldn't have any mention of the Extension you don't want to use (or possibly shouldn't even be there if you don't have any extensions or target dependencies.