简体   繁体   中英

How to enable push notification in Xcode 11?

I'm trying to enable push notification in Xcode 11.0. I have added push notifications form + capability but enable or disable button is not there.

能力截图

For Xcode v11.2.1 at least the button to add capabilities is in the upper left corner. Once you add a new capabilitiy it's enabled by default. To disable, you delete the capability. See Screenshot for a little more detail. Capability SS

In Xcode 11 or above update some many things. For push notification enable and disable check the attack screen short.

On top Upper corner click on capability:

在顶部上角单击功能

push notification when you click then automatically enable:

另一张图片在您单击时显示推送通知,然后自动启用

if you want disable then -> TARGETS -> Signing & Capabilities and scroll down click on cross for disable

Strange but push notification is not listed for me. - Tejas K

Me too! This is another Xcode bug I have found. You can workaround it by unchecking and rechecking the Automatically manage signing box , you should see a longer list of capabilities now:

弹出功能的图像

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM