matyunya / smelte

UI framework with material components built with Svelte and Tailwind CSS

Home Page:https://smeltejs.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

new project setup broken, can't find tailwind (404)

dctalbot opened this issue Β· comments

  Your application is ready~! πŸš€

  - Local:      http://localhost:5000
  - Network:    Add `--host` to expose

────────────────── LOGS ──────────────────

  [01:57:59] 200 ─ 3.37ms ─ /
  [01:57:59] 200 ─ 0.59ms ─ /global.css
  [01:57:59] 200 ─ 0.88ms ─ /build/bundle.css
  [01:57:59] 200 ─ 1.72ms ─ /build/bundle.js
  [01:57:59] 404 ─ 0.14ms ─ /build/tailwindcss/base
  [01:57:59] 404 ─ 0.11ms ─ /build/tailwindcss/components
  [01:57:59] 404 ─ 0.10ms ─ /build/tailwindcss/utilities

I'm a bit new to the svelte/rollup space, but I followed the docs pretty straight forwardly and the css isn't being applied. I wonder if a dependency regression was introduced?

Steps to reproduce:

npx degit sveltejs/template my-svelte-project
cd my-svelte-project
npm install
npm install smelte

Add const smelte = require("smelte/rollup-plugin-smelte"); to top of rollup.config.js
Add smelte as last plugin in rollup.config.js (see README)
Add import "smelte/src/tailwind.css";
Add some example smelte components

npm run dev

See no styles being applied.

In rollup.config.js put the smelte plugin right after the svelte plugin.
Not sure, which plugin interferes, but it is much likely the css plugin. I think the documentation regarding this should be updated.

Thanks @micha-lmxt , that solved it!