Skip to content

Commit 5deac4b

Browse files
committed
rename
1 parent b0231a9 commit 5deac4b

File tree

4 files changed

+26
-26
lines changed

4 files changed

+26
-26
lines changed

src/components/WranglerCommands.astro renamed to src/components/WranglerNamespace.astro

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ const defs = experimental_getWranglerCommands();
1414
const node = defs.subtree.get(namespace);
1515
1616
if (!node || node.subtree.size === 0) {
17-
throw new Error(`[WranglerCommands] Namespace "${namespace}" not found`);
17+
throw new Error(`[WranglerNamespace] Namespace "${namespace}" not found`);
1818
}
1919
2020
const definitions: NonNullable<(typeof node)["definition"]>[] = [];
@@ -36,7 +36,7 @@ flattenSubtree(node.subtree);
3636
definitions.map((definition) => {
3737
if (definition.type !== "command") {
3838
throw new Error(
39-
`[WranglerCommands] Expected "command" but got "${definition.type}" for "${definition.command}"`,
39+
`[WranglerNamespace] Expected "command" but got "${definition.type}" for "${definition.command}"`,
4040
);
4141
}
4242
return (

src/components/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ export { default as TunnelCalculator } from "./TunnelCalculator.astro";
5858
export { default as Type } from "./Type.astro";
5959
export { default as TypeScriptExample } from "./TypeScriptExample.astro";
6060
export { default as WranglerCommand } from "./WranglerCommand.astro";
61-
export { default as WranglerCommands } from "./WranglerCommands.astro";
61+
export { default as WranglerNamespace } from "./WranglerNamespace.astro";
6262
export { default as WranglerConfig } from "./WranglerConfig.astro";
6363
export { default as WARPReleases } from "./WARPReleases.astro";
6464
export { default as Width } from "./Width.astro";

src/content/docs/style-guide/components/wrangler-commands.mdx

Lines changed: 0 additions & 23 deletions
This file was deleted.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
title: WranglerNamespace
3+
styleGuide:
4+
component: WranglerNamespace
5+
---
6+
7+
The `WranglerNamespace` component documents the available commands for a given namespace.
8+
9+
This is generated using the Wrangler version in the [`cloudflare-docs` repository](https://github.com/cloudflare/cloudflare-docs/blob/production/package.json).
10+
11+
## Import
12+
13+
```mdx
14+
import { WranglerNamespace } from "~/components";
15+
```
16+
17+
## Usage
18+
19+
```mdx live
20+
import { WranglerNamespace } from "~/components";
21+
22+
<WranglerNamespace namespace="d1" />
23+
```

0 commit comments

Comments
 (0)