devcert icon indicating copy to clipboard operation
devcert copied to clipboard

Allow IP address as domains

Open evsar3 opened this issue 2 years ago • 1 comments

This PR allow users to also use IP addresses as domain options while generating certificates.

Eg.:

import * as devcert from 'devcert'

const ssl = await devcert.certificateFor([
  'somedomain.local',
  'localhost',
  '192.168.1.2',
  '127.0.0.1'
])

PS.: It would be much less changes, but my VS Code has the organizeImports feature enable, so when I saved the files it have sorted and organized the imports. If that's a problem, I can undo this before merge (if you want).

Congratulations for the great tool. 😄

evsar3 avatar Jan 26 '23 20:01 evsar3