Yummygum / flagpack-core

Flagpack contains 250+ flag icons to easily use within your code project.
https://flagpack.xyz
MIT License
589 stars 128 forks source link

Webpack Loaders Error on Next.js #29

Closed punctuations closed 3 years ago

punctuations commented 3 years ago

Please check all that apply

Expected Behavior

Should throw no errors and work fine.

Current Behavior

Throws error about incorrect webpack loader.

Steps to Reproduce

  1. Create next app
  2. install react-flagpack
  3. add import statement
  4. run dev
  5. observe logs

Screenshots

image

Logs

error - ./node_modules/flagpack-core/dist/flags/cXaxgftL.svg 1:0
Module parse failed: Unexpected token (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
> <svg width="16" height="12" viewBox="0 0 16 12" fill="none" xmlns="http://www.w3.org/2000/svg">
| <mask id="mask0" mask-type="alpha" maskUnits="userSpaceOnUse" x="0" y="0" width="16" height="12">
| <rect width="16" height="12" fill="white"/>

Context

Unable to use flagpack at all :(

Your Environment

punctuations commented 3 years ago

my apologies this was on the react-flagpack repo in this pull request https://github.com/Yummygum/react-flagpack/pull/26