Merge-CIDRs
Given a pair of CIDR blocks, return the smallest CIDR which encompasses both of the original CIDR blocks.
Install with:
npm install merge-cidrs
Usage
var mergeCidrs = ; // Using strings (in this example two adjacent /32 CIDR blocks representing the individual IP address)var subnet = ;console; // If you already have ip.cidrSubnets you can use those too. (In this example a /32 and an overlapping /30 CIDR block.)var subnetA = ip;var subnetB = ip;var merged = ;console;