我可以将可变内容与本地推送通知一起使用而不是远程通知吗?
Can I use mutable-content with local push notification instead of remote notification?
我可以将可变内容与本地推送通知一起使用而不是远程通知吗?
例如在userInfo中发送,使用Notification Service Extension。
没有。
如果您使用的是可变内容和通知服务扩展,那么根据 Apple doc 它清楚地说明:-
An object that modifies the content of a remote notification before it
is delivered to the user.
因此您不能使用服务扩展来修改本地通知的内容,然后再将其发送给用户。
但是,如果您尝试显示自定义界面,您始终可以使用 content extension 进行本地通知。
希望它澄清。
我可以将可变内容与本地推送通知一起使用而不是远程通知吗?
例如在userInfo中发送,使用Notification Service Extension。
没有。
如果您使用的是可变内容和通知服务扩展,那么根据 Apple doc 它清楚地说明:-
An object that modifies the content of a remote notification before it is delivered to the user.
因此您不能使用服务扩展来修改本地通知的内容,然后再将其发送给用户。
但是,如果您尝试显示自定义界面,您始终可以使用 content extension 进行本地通知。
希望它澄清。