@symbolic/lib
Advanced tools
Comparing version 1.0.25 to 1.0.26
@@ -126,6 +126,15 @@ 'use strict'; | ||
var sf = {api, colors}; | ||
var validation = {}; | ||
validation.emailIsValid = (email) => { | ||
var re = /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/; | ||
return re.test(String(email).toLowerCase()); | ||
}; | ||
var sf = {api, colors, validation}; | ||
exports.api = api; | ||
exports.colors = colors; | ||
exports.default = sf; | ||
exports.validation = validation; |
{ | ||
"name": "@symbolic/lib", | ||
"version": "1.0.25", | ||
"version": "1.0.26", | ||
"description": "plain js utilities", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
import api from './api/api'; | ||
import colors from './colors/colors'; | ||
import validation from './validation/validation'; | ||
var sf = {api, colors}; | ||
var sf = {api, colors, validation}; | ||
export default sf; | ||
export {api, colors}; | ||
export {api, colors, validation}; |
8419
10
245