svengau / tailwindcss-hero-patterns

A simple tailwind plugin to display Hero Patterns by @steveschoger.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Version 0.1.0 not working

AlexMNet opened this issue · comments

Hi! First off thank you for creating this project! I have used it in a previous application and now implementing it in a new one.

I realized when installing that there was a new version 0.1.0 which is not currently working for me.

 "dependencies": {
    "@headlessui/react": "^1.7.11",
    "@headlessui/tailwindcss": "^0.1.2",
    "@heroicons/react": "^2.0.16",
    "@next/font": "13.1.6",
    "eslint": "8.34.0",
    "eslint-config-next": "13.1.6",
    "next": "13.1.6",
    "react": "18.2.0",
    "react-dom": "18.2.0",
    "react-player": "^2.11.2",
    "tailwindcss-hero-patterns": "^0.1.0"
  },
  "devDependencies": {
    "autoprefixer": "^10.4.13",
    "eslint-config-prettier": "^8.6.0",
    "eslint-plugin-prettier": "^4.2.1",
    "postcss": "^8.4.21",
    "prettier": "^2.8.4",
    "prettier-plugin-tailwindcss": "^0.2.3",
    "tailwindcss": "^3.2.7"
  }

It does work when I install the previous version 0.0.1. Any clue what could be going on here? Thank you!

commented

Thanks for reporting this @AlexMNet. I can reproduce the issue too. V0.0.2 works fine (here is a playground link)

@pySilver it seems this issue has been introduced with #6. Did you get a chance to test it ?

@svengau at the moment I'm still using my fork version and it works just fine. Do you see any errors or it is simply not generating anything? Does it work with something like heropattern-foo-red-100/50 ?

Oh. My bad. I've accidentally changed base class prefix name from 'heropattern' to 'pattern' and committed it like that. This is the issue here.

commented

@pySilver do you mind pushing a PR to fix it ? thx

@svengau #8 here it is :)

@svengau @pySilver just reading all this now. Thank you both for your prompt work on this issue!

commented

I've just published a new version.

Also, I've introduced a new params heroPatternsOpacities with default to ['10', '50', '90'], to optimize the load (it wasn't loading properly in the tailwind css playground).

@svengau out of curiosity: Is that needed for development mode for some reason? I don't see any unwanted classes being generated thanks to JIT. (Maybe its been generated, but cleared at the very end, I've never actually looked into internal JIT logic)