I'm guessing the new way of handling the utilsScript is what's causing the issue. Right now we're doing what is outlined in the Initialisation options by providing an URL to the script. We're also using Vue so the React bundle with the utils script included won't work for us.
With the changes introduced in v23.0.0 that dynamically imports the utils script file rather than injecting a script tag, our Webpack setup seems to have an issue with the dynamic import. More specifically it has a problem with the loadUtils method:
Plugin version
v23.0.4
Steps to reproduce
intlTelInput
intlTelInput(input, { utilsScript: <url_to_script> })
Expected behaviour
Input should be initialized and working.
Actual behaviour
The webpack compilation fails with the following error:
Initialisation options
Here's how our initialisation looks:
Additional information
I'm guessing the new way of handling the
utilsScript
is what's causing the issue. Right now we're doing what is outlined in the Initialisation options by providing an URL to the script. We're also using Vue so the React bundle with the utils script included won't work for us.With the changes introduced in v23.0.0 that dynamically imports the utils script file rather than injecting a script tag, our Webpack setup seems to have an issue with the dynamic import. More specifically it has a problem with the
loadUtils
method:And most likely the
import(path).then()
method is the real culprit, as @BRAiNCHiLD95 also confirmed in #1616.We're using Webpack v.5 if it's of any help.