code-dumps/nodejs/dnslookup.js

3 lines
121 B
JavaScript
Raw Normal View History

2023-04-21 13:01:56 +08:00
const dns = require('dns');
dns.lookup('blog.headdesk.me', (err,address,family) => console.log('results: %s', address));