is-mailto
Simple function to test if an url is a valid "mailto:".
Install:
$ npm i is-mailto
$ yarn add is-mailto
Example:
; const string = 'mailto:test@test.com';console // true const string = 'test@test';console // false because it's not an valid email and not contain "mailto:"