shadcn-ui / ui

Beautifully designed components that you can copy and paste into your apps. Accessible. Customizable. Open Source.
https://ui.shadcn.com
MIT License
74.66k stars 4.64k forks source link

[bug]: No Tailwind CSS configuration found in svelte base project #5584

Closed s1n7ax closed 3 weeks ago

s1n7ax commented 3 weeks ago

Describe the bug

I'm unable to add any components to svelte base project I just created due to the error mentioned in the title. This is a brand new project created today.

Affected component/components

*

How to reproduce

  1. Create a new svelte project npx sv create sample

    ❯ npx sv create sample
    ┌  Welcome to the Svelte CLI! (v0.5.9)
    │
    ◇  Which template would you like?
    │  SvelteKit minimal
    │
    ◇  Add type checking with Typescript?
    │  Yes, using Typescript syntax
    │
    ◆  Project created
    │
    ◇  What would you like to add to your project? (use arrow keys / space bar)
    │  tailwindcss
    │
    ◇  Preconditions not met ────────────────────────────╮
    │                                                    │
    │  - clean working directory (Found modified files)  │
    │                                                    │
    ├────────────────────────────────────────────────────╯
    │
    ◇  Preconditions failed. Do you wish to continue?
    │  Yes
    │
    ◇  Which plugins would you like to add?
    │  none
    │
    ◇  Which package manager do you want to install dependencies with?
    │  pnpm
    │
    ◆  Successfully setup integrations
  2. Navigate to the project and run npx shadcn@latest init

❯ npx shadcn@latest init
✔ Preflight checks.
✔ Verifying framework. Found Vite.
✖ Validating Tailwind CSS.
✖ Validating import alias.

No Tailwind CSS configuration found at /home/s1n7ax/Workspace/open-song-lyrics.
It is likely you do not have Tailwind CSS installed or have an invalid configuration.
Install Tailwind CSS then try again.
Visit https://tailwindcss.com/docs/guides/vite to get started.

No import alias found in your tsconfig.json file.
Visit https://ui.shadcn.com/docs/installation/vite to learn how to set an import alias.

Codesandbox/StackBlitz link

No response

Logs

No response

System Info

"@sveltejs/kit": "^2.0.0",
    "@sveltejs/vite-plugin-svelte": "^4.0.0",
    "svelte": "^5.0.0",
    "tailwindcss": "^3.4.9",
    "vite": "^5.0.3",
❯ pnpm --version
9.12.1


### Before submitting

- [X] I've made research efforts and searched the documentation
- [X] I've searched for existing issues
s1n7ax commented 3 weeks ago

wait!, I thought this supports svelte. My bad!