# wx.onLocalServiceFound(function callback)
Start from base library version 2.4.0. Please remaining backward compatible.
with Promise style call: Not supported
Mini Program plugin: Support, need to Mini Program base library version no less than 2.15.0
to monitor mDNS Events discovered by services
# parameter
# function callback
mDNS Callback function for events discovered by the service
# parameter
# Object res
attribute | type | Introductions |
---|---|---|
serviceType | string | Types of Services |
serviceName | string | Name of service |
ip | string | Service ip address |
port | number | Service Port |