mhanberg / jekyll-postcss

A plugin to use PostCSS plugins like Autoprefixer or Tailwind CSS with Jekyll.
MIT License
66 stars 12 forks source link

Error: UnhandledPromiseRejectionWarning: CssSyntaxError #12

Closed DirtyF closed 4 years ago

DirtyF commented 4 years ago

๐Ÿ‘‹ It's the first time I try to use postcss and tailwind starter and I run into errors I tried bumping up the packages but same, am I doing something wrong here?

JEKYLL_ENV=production bundle exec jekyll build --trace
      Generating...
(node:68881) UnhandledPromiseRejectionWarning: CssSyntaxError: <css input>:92817:175: Unclosed string
    at Input.error (/Users/frank/code/100-km-jekyll-tailwind/node_modules/purgecss/node_modules/postcss/lib/input.js:130:16)
    at unclosed (/Users/frank/code/100-km-jekyll-tailwind/node_modules/purgecss/node_modules/postcss/lib/tokenize.js:50:17)
    at Object.nextToken (/Users/frank/code/100-km-jekyll-tailwind/node_modules/purgecss/node_modules/postcss/lib/tokenize.js:159:15)
    at Parser.other (/Users/frank/code/100-km-jekyll-tailwind/node_modules/purgecss/node_modules/postcss/lib/parser.js:153:30)
    at Parser.parse (/Users/frank/code/100-km-jekyll-tailwind/node_modules/purgecss/node_modules/postcss/lib/parser.js:77:16)
    at Function.parse (/Users/frank/code/100-km-jekyll-tailwind/node_modules/purgecss/node_modules/postcss/lib/parse.js:17:12)
    at x.getPurgedCSS (/Users/frank/code/100-km-jekyll-tailwind/node_modules/purgecss/lib/purgecss.js:1:6739)
    at async /Users/frank/code/100-km-jekyll-tailwind/node_modules/purgecss/bin/purgecss:58:18
(node:68881) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:68881) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

The CSS file is:

---
---

@import "tailwindcss/base";
@import "tailwindcss/components";
@tailwind utilities;

Repository: https://github.com/DirtyF/100-km-jekyll-tailwind

Env:

Thanks for any insight you could provide here.

DirtyF commented 4 years ago

Sorry I meant to open this in purgecss repo ๐Ÿ˜Š

mhanberg commented 4 years ago

Do you mind sharing your postcss and purgecss configs?

mhanberg commented 4 years ago

I closed this since it seems to be a purgecss issue and not because of this project.

I will note that there might be something going on related to Tailwinds builtin purgecss support