qonto/ember-phone-input

Not compiling on Ember 5

Closed this issue · 3 comments

Hi all! Probably I am missing something pretty obvious here, but for some reason, after installing ember-phone-input in a newly created ember app with Ember 5, my app is not compiling any more. I have the following error from ember-auto-import:

ERROR in ./node_modules/intl-tel-input/build/img/flags.png 1:0
Module parse failed: Unexpected character '�' (1:0)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
(Source code omitted for this binary file)
 @ ./node_modules/css-loader/dist/cjs.js!./node_modules/ember-phone-input/dist/styles/styles.css 4:0-88 7:73-102
 @ ./node_modules/ember-phone-input/dist/styles/styles.css 2:12-81 9:17-24 13:15-29
 @ ./node_modules/ember-phone-input/dist/components/phone-input.js 1:368-397
 @ ../../../../../private/var/folders/z6/9q3xj7zn60n2xm64z68t868m0000gn/T/broccoli-69888Etfv1hkx9N2x/cache-238-webpack_bundler_ember_auto_import_webpack/app.cjs 20:144-195

Should I add any specific loader in my ember-cli-build.js file to be able to handle the flag.png files? Any recommendations?

Thanks!

Alejandro

@aburto22
https://github.com/qonto/ember-phone-input/blob/master/test-app/ember-cli-build.js
You have to include autoImport configuration to your ember-cli-build.js to make it work.

Hi, thanks for you comment! Silly me, didn`t think of looking into the project test-app. Will try it out soon and see if it works, thanks!

it works, thanks for your suggestion @Gothamoo7!