Unable to install Shadcn components
Environment
- Operating System version: Debian GNU/Linux 12 (bookworm)
- Firebase UI version: v7.0.0-beta
- Firebase SDK version: 12.6.0
- Package name: @firebase-oss/ui-react'
Problem
Running npx shadcn@latest add @firebase/sign-in-auth-screen yields:
Something went wrong. Please check the error below for more details.
If the problem persists, please open an issue on GitHub.
Command failed with exit code 1: npm install '@radix-ui/react-separator' '@radix-ui/react-slot' '@radix-ui/react-label' '@firebase-oss/ui-react' input-otp '@hookform/resolvers' zod react-hook-form
npm error code EUNSUPPORTEDPROTOCOL
npm error Unsupported URL Type "catalog:": catalog:peerDependencies
The problem was narrowed to the installation of @firebase-oss/ui-react' (other packages can be installed no problem).
Looking at its package.json, it seems this may be the culprit:
// ...
"peerDependencies": {
"firebase": "catalog:peerDependencies",
"react": "catalog:peerDependencies",
"react-dom": "catalog:peerDependencies"
},
+1 same issue for me as well
Looks like the packages have been publushed with npm rather than pnpm - cc @jhuleatt might be worth a sync here to figure out how we can get the publish flow automated through Cloud Build / action.
@Ehesp the react components are published correctly on the beta npm tag. However, the shadcn registry isn't referencing beta, it's referencing latest. Example:
"dependencies": [
"@firebase-oss/ui-react"
]
this should say "@firebase-oss/ui-react@beta" in the registry file https://github.com/firebase/firebaseui-web/blob/3d019489102ce0de67dcf33a518552861c773bc1/packages/shadcn/registry-spec.json#L14
I should probably unpublish 0.0.1 on the latest tag, that doesn't have the latest code anyway.
Still broken for me. Running bunx --bun shadcn@latest add @firebase/sign-in-auth-screen installs components which import @/components/ui/form:
import { Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage } from "@/components/ui/form";
The problem is that @/components/ui/form doesn't exist. Running bunx --bun shadcn@latest add form just says ✔ Checking registry. and nothing gets installed.