Adding DNS support can be large but one option would be to trim the [DNS component](https://github.com/pimoroni/phew/blob/main/phew/dns.py) out of the [phew](https://github.com/pimoroni/phew) library. Appears to be small and contained and it seems like [at least one user](https://github.com/miguelgrinberg/microdot/discussions/141) has used phew's captive portal in conjunction with microdot.