Avatar
Kishikawa Katsumi 4/7/2022 9:35 AM
表示する値がサーバーサイドでわかっているならPush通知のPayloadにバッジの数を入れたらいいです。 https://developer.apple.com/documentation/usernotifications/setting_up_a_remote_notification_server/generating_a_remote_notification クライアント(アプリ)で何か処理をしないとわからないのであれば、 https://developer.apple.com/documentation/uikit/uiapplicationdelegate/1623013-application ^このメソッドが呼ばれるはずなのでそこでバッジの数を更新できると思います。 それかNotification Extensionを作成すればかなり自由に処理を書けるはずです。