next-domain
Get url domain for next.
installation
npm install -S @jswork/next-domain
usage
import '@jswork/next-domain';
// normal
nx.domain('https://www.baidu.com/'); // baidu.com
// 2 level
nx.domain('http://12345.i.taobao.com', 2); // taobao.com
license
Code released under the MIT license.