You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi all,
I am working on a project based on requireJS and I'm trying to load NDIP only when a date input is present in page. if(document.querySelector("input[type='date']")!==null) require(["libs/nodep-date-input-polyfill.dist"]);
The problem is: the polyfill is triggered whichever browser I use, duplicating the native behavior.
No problem if I hardcode the script in my page, prior the removal of ('function'==typeof define&&define.amd?define(b): which would trigger a requirejs error). Firefox would show the native interface, IE11 would show the polyfill.
Can you reproduce this problem?
The text was updated successfully, but these errors were encountered:
massic80
changed the title
When loaded ad AMD module, it's triggered everywhere
When loaded as AMD module, it's triggered everywhere
Feb 21, 2018
Hi all,
I am working on a project based on requireJS and I'm trying to load NDIP only when a date input is present in page.
if(document.querySelector("input[type='date']")!==null) require(["libs/nodep-date-input-polyfill.dist"]);
The problem is: the polyfill is triggered whichever browser I use, duplicating the native behavior.
No problem if I hardcode the script in my page, prior the removal of (
'function'==typeof define&&define.amd?define(b):
which would trigger a requirejs error). Firefox would show the native interface, IE11 would show the polyfill.Can you reproduce this problem?
The text was updated successfully, but these errors were encountered: