Hi, I want to proposal to add cdn instructions in the readme, we can use https://unpkg.com/
In that way, we will have a cdn method to add validator.js in client-side.
Can I make a PR?
Many people are using unpkg to load JS libraries. I really think it's a great idea to add instructions for that purpose specially that validator.min.js will be removed from the repo
@ezkemboi @profnandaa any feedback on this?
Sounds good to me, let's do that. Thanks!
Busy working on some work, but here's the address if anyone has time to update the readme. If I can, I'll get to it before end of day.
https://unpkg.com/validator.js@latest/dist/validator.min.js
Edit: Of course I say that, but didn't test that min.js worked for me. Derp.
In theory, the below should work?
<script type="text/javascript" src="https://unpkg.com/validator.js@latest/dist/validator.min.js"></script>
<script type="text/javascript">
console.log(validator.isEmail('[email protected]')); //=> true
</script>
Sure @Brutalbeard. Please if you get sometime later in the day, you can add it.
We will appreciate it.
@ezkemboi, @profnandaa, @luiscobits or @tux-tn, can anyone just double check that they have no issue bringing this into a basic HTML page?
I'll have a pull request for the readme ready if you give the go ahead.
Hey all. Just bumping on this. Haven't used unpkg.com before. Thinking there may be some other dependency to add?
@ezkemboi, @profnandaa, @luiscobits, @tux-tn
Thanks @Brutalbeard!
No, Unpkg do not need anything else, only the link that you pointed out before.
PR on its way!
Most helpful comment
In theory, the below should work?