For example: the local IP (not loopback) will change if the active network interface changed. How to detect it? OR: how to detect the active network interface change event?
See here Get local IP address in Node.js
os.networkInterfaces() can retrieve list of addresses and interfaces. Create a timeout to detect the appropriate differences and handle it appropriately when change is detected.
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.