But there is no example code or guides, and I am quite new to angularJS and Ionic. So how to use this plugin? and how can I derive that from the plugin code?
When you got no documentation, you have to open the plugin file and see what’s implemented.
In the plugin.xml file, you can see there is a <clobbers target="multicastDNS" /> tag, which means this will be the global JS variable the plugin will rely on.
After that, you open the actual .js file to see the exported methods:
module.exports = {
query: ...
}
So, there will be a global object named multicastDNS with a query method in it.
Just call multicastDNS.query(host, multicastIP, port, successCallback, errorCallback); from your controller.
BTW, because the plugin is not documented nor tested, I believe it’s not even working as expected.