Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build error in vue-plyr.css when using @nuxt/postcss8 #359

Open
ateliershen opened this issue Apr 20, 2021 · 12 comments
Open

Build error in vue-plyr.css when using @nuxt/postcss8 #359

ateliershen opened this issue Apr 20, 2021 · 12 comments

Comments

@ateliershen
Copy link

Hi,

I am using Nuxt.js v2.15.4 and vue-plyr 7. It throws the following error when running the build command:

08:32:12.800 ERROR in ./node_modules/vue-plyr/dist/vue-plyr.css (./node_modules/@nuxt/postcss8/node_modules/css-loader/dist/cjs.js??ref--3-oneOf-1-1!./node_modules/@nuxt/postcss8/node_modules/postcss-loader/dist/cjs.js??ref--3-oneOf-1-2!./node_modules/vue-plyr/dist/vue-plyr.css)
08:32:12.800 Module build failed (from ./node_modules/@nuxt/postcss8/node_modules/postcss-loader/dist/cjs.js):
08:32:12.800 ParserError: Syntax Error at line: 1, column 50
08:32:12.800 at node_modules/vue-plyr/dist/vue-plyr.css:1:2235

I am following the SSR instructions from the readme, using the exact same settings.
Is anyone else encountering the same issue? Thanks.

@riderx
Copy link

riderx commented Apr 22, 2021

Same here

@dargmuesli
Copy link

With postcss v8.2.12 I receive the error

#22 33.41 ParserError: Syntax Error at line: 1, column 51
#22 33.41     at /srv/app/node_modules/plyr/dist/plyr.css:1:2198

See this build log

@frederic117
Copy link

I got the same error
Module build failed (from ./node_modules/postcss-loader/src/index.js): friendly-errors 16:17:14
ParserError: Syntax Error at line: 1, column 51
at .....\node_modules\plyr\dist\plyr.css:1:2198
Nuxt 2.15.4 and last version.
It works with plyr: 3.6.4

thks for the help

@elihorne
Copy link

I'm experiencing the same problem. I tried rolling postcss back from 8.2.12 to 8.2.10, but the error remains.

@elihorne
Copy link

elihorne commented Apr 27, 2021

As an interim workaround, I've removed Plyr's css from my plugin file, and instead am pulling it from the unpkg CDN. It now successfully generates the build.

export default {
  head() {
    return {
      link: [
        {
          rel: 'stylesheet',
          href: 'https://unpkg.com/vue-plyr/dist/vue-plyr.css',
        },
      ],
    }
  },
}

@riderx
Copy link

riderx commented May 24, 2021

Same in my side, in plus vue-jlyr is really big so use cdn for the only page I use was a better solution

@saschaeggi
Copy link

Same issue here

@lustremedia
Copy link

I also would love to see this issue fixed!

@lustremedia
Copy link

I also get the error with postcss7 and vue-plyr, so I am wondering if postcss is really the culprit here...

@unremarkablegarden
Copy link

Still broken on my end.

@riderx
Copy link

riderx commented Oct 29, 2021

@unremarkablegarden the solution of @elihorne is working if you need a workaround

@dargmuesli
Copy link

Now that postcss-preset-env v7 is out, monitor nuxt/nuxt#10060 and nuxt/nuxt#9671.
In the meantime you can add the following to your package.json:

  "resolutions": {
    "postcss-preset-env": "7.0.1"
  }

Please tell if that workaround works for you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants