guillaumepotier / Parsley.js

Validate your forms, frontend, without writing a single line of javascript
http://parsleyjs.org
MIT License
9.05k stars 1.32k forks source link

max date validation failing on chrome ONLY with minified version #1321

Closed hanoii closed 4 years ago

hanoii commented 4 years ago

This is an odd issue, I was reported of this issue on a project,

https://codepen.io/hanoii/pen/YzzRGgq

Simply hit submit and parsely will throw the error. I debugged the minified version and it seems that the max operator comparison is getting a "yyyy-mm-dd" while the requirement is a date object.

I believe that the issue is in a line that was not properly minified.

See the a working codepen where the only difference is that is using the non-minified version:

https://codepen.io/hanoii/pen/xxxQENK

marcandre commented 4 years ago

Hi! I'm really grateful that you seem to have looked deeper in this issue, and I'm sorry it's there at all. For the first time if my life, I don't have my computer with me, as I'm trekking the Annapurna circuit! I will be reunited with my laptop in about two weeks; I'll either look at this on a plane or when I'm back home in early December...

hanoii commented 4 years ago

@marcandre wow, awesome. The fact that you replied to this while trekking is even more mind boggling than the bug itself. Please enjoy and don't restrain yourself from attaching pictures here, always nice to dress a github issue a bit.

marcandre commented 4 years ago

PANO_20191115_110743

Today's destination was Tilicho lake at almost 5000m :-)

guillaumepotier commented 4 years ago

Whoa, impressive ;) What kind of wide-angle to you have there? 14mm?

hanoii commented 4 years ago

My money is on a iPhone panorama :).

marcandre commented 4 years ago

@hanoii almost has it, but I'm using an android phone.

marcandre commented 4 years ago

I battled with the tooling, updated the versions and when I managed to get it to compile again, the minimized version was correct. v2.9.2 should be ok.

Thanks again for the great detective work 🕵️‍♂️