In order to support multiple web3 libraries - maticjs provides plugins.
Currently two libraries are supported -
You can also use the Unstoppable Domains resolution plugin from the maticjs utils namespace.
utils