Skip to content

Commit 80c1d81

Browse files
committed
refactor(shadcn): Move registry items to public/r
1 parent 8c301a1 commit 80c1d81

File tree

4 files changed

+5
-4
lines changed

4 files changed

+5
-4
lines changed

examples/shadcn/components.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
"hooks": "@/hooks"
2020
},
2121
"registries": {
22-
"@dev": "http://localhost:5177/{name}.json",
23-
"@firebase-ui": "https://ui.firebase.com/{name}.json"
22+
"@dev": "http://localhost:5177/r/{name}.json",
23+
"@firebase-ui": "https://ui.firebase.com/r/{name}.json"
2424
}
2525
}

packages/shadcn/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
registry.json
33
# Vite builds the shadcn components during development to here
44
public-dev/
5+
public/r/
56

67
# Logs
78
logs

packages/shadcn/build.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import { execSync } from "child_process";
55

66
const args = parser(process.argv.slice(2));
77
const domain = String(args.domain);
8-
const publicDir = args.publicDir ? String(args.publicDir) : "public";
8+
const publicDir = args.publicDir ? String(args.publicDir) : "public/r";
99
const isDev = !!args.dev;
1010

1111
if (!domain) {

packages/shadcn/vite.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ export default defineConfig({
1717
{
1818
name: "build registry",
1919
pattern: ["src/components/**/*.tsx", "registry-spec.json"],
20-
run: ["tsx", "build.ts", "--domain", "http://localhost:5177", "--publicDir", "public-dev", "--dev"],
20+
run: ["tsx", "build.ts", "--domain", "http://localhost:5177", "--publicDir", "public-dev/r", "--dev"],
2121
},
2222
]),
2323
],

0 commit comments

Comments
 (0)