JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 514887
  • Score
    100M100P100Q190399F
  • License MIT

Validate domain name

Package Exports

  • is-valid-domain

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (is-valid-domain) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

is-valid-domain

Validate domain name

Install

npm install is-valid-domain

Usage

var isValidDomain = require('is-valid-domain');

isValidDomain('example.com') // true
isValidDomain('foo.example.com') // true
isValidDomain('bar.foo.example.com') // true
isValidDomain('exa-mple.co.uk') // true
isValidDomain('exa_mple.com') // false
isValidDomain('example') // false
isValidDomain('ex*mple.com') // false
isValidDomain(3434) // false

License

MIT