Skip to content

Commit 279071d

Browse files
committed
Replacing relative paths to absolute paths.
1 parent f929620 commit 279071d

File tree

3 files changed

+20
-20
lines changed

3 files changed

+20
-20
lines changed

src/content/docs/durable-objects/api/id.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@ import { Tabs, TabItem } from "~/components";
99

1010
## Description
1111

12-
The `DurableObjectId` interface refers to a new or existing Durable Object instance. This interface is most frequently used by [`DurableObjectNamespace::get`](./namespace.mdx) to obtain a stub for submitting requests to the Durable Object class.
12+
The `DurableObjectId` interface refers to a new or existing Durable Object instance. This interface is most frequently used by [`DurableObjectNamespace::get`](/durable-objects/api/namespace/#get) to obtain a stub for submitting requests to the Durable Object class.
1313

14-
Note that creating an ID for a Durable Object instance does not invoke the constructor of the Durable Object. This is done lazily when calling [`DurableObjectNamespace::get`](../namespace/#get) to create a [`DurableObjectStub`](../stub) from a `DurableObjectId`. This ensures that objects are not constructed unless their methods can be directly invoked.
14+
Note that creating an ID for a Durable Object instance does not invoke the constructor of the Durable Object. This is done lazily when calling [`DurableObjectNamespace::get`](/durable-objects/api/namespace/#get) to create a [`DurableObjectStub`](/durable-objects/api/stub) from a `DurableObjectId`. This ensures that objects are not constructed unless their methods can be directly invoked.
1515

1616
:::note[`DurableObjectId`]
1717

@@ -70,7 +70,7 @@ A boolean. True if equal and false otherwise.
7070

7171
#### Description
7272

73-
`name` is an optional property of a `DurableObjectId`, which returns the name that was used to create the `DurableObjectId` via [`DurableObjectNamespace::idFromName`](../namespace/#idfromname). This value is undefined if the `DurableObjectId` was constructed using [`DurableObjectNamespace::newUniqueId`](../namespace/#newuniqueid).
73+
`name` is an optional property of a `DurableObjectId`, which returns the name that was used to create the `DurableObjectId` via [`DurableObjectNamespace::idFromName`](/durable-objects/api/namespace/#idfromname). This value is undefined if the `DurableObjectId` was constructed using [`DurableObjectNamespace::newUniqueId`](/durable-objects/api/namespace/#newuniqueid).
7474

7575
```js
7676
const id1 = env.MY_DURABLE_OBJECT.newUniqueId();

src/content/docs/durable-objects/api/namespace.mdx

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import { Tabs, TabItem } from "~/components";
1111

1212
The `DurableObjectNamespace` interface is used to obtain a reference to a new or existing Durable Object instance. The interface is accessible from the fetch handler on a Cloudflare Worker via the `env` parameter, which is the standard interface when referencing bindings declared in `wrangler.toml`.
1313

14-
This interface defines several [methods](../namespace/#methods) that can be used to create an ID for a Durable Object instance. Note that creating an ID for a Durable Object instance does not invoke the constructor of the Durable Object. This is done lazily when calling [`DurableObjectNamespace::get`](../namespace/#get) to create a [`DurableObjectStub`](../stub) from a `DurableObjectId`. This ensures that objects are not constructed unless their methods can be directly invoked.
14+
This interface defines several [methods](/durable-objects/api/namespace/#methods) that can be used to create an ID for a Durable Object instance. Note that creating an ID for a Durable Object instance does not invoke the constructor of the Durable Object. This is done lazily when calling [`DurableObjectNamespace::get`](/durable-objects/api/namespace/#get) to create a [`DurableObjectStub`](/durable-objects/api/stub) from a `DurableObjectId`. This ensures that objects are not constructed unless their methods can be directly invoked.
1515

1616
<Tabs> <TabItem label="JavaScript" icon="seti:javascript">
1717

@@ -71,7 +71,7 @@ export default {
7171

7272
#### Description
7373

74-
`idFromName` creates a [`DurableObjectId`](../id) which refers to an individual instance of the Durable Object class from a particular name.
74+
`idFromName` creates a [`DurableObjectId`](/durable-objects/api/id) which refers to an individual instance of the Durable Object class from a particular name.
7575

7676
```js
7777
const fooId = env.MY_DURABLE_OBJECT.idFromName("foo");
@@ -80,11 +80,11 @@ const barId = env.MY_DURABLE_OBJECT.idFromName("bar");
8080

8181
#### Parameters
8282

83-
The string to be used to generate a [`DurableObjectId`](../id) corresponding to the name of a Durable Object instance.
83+
The string to be used to generate a [`DurableObjectId`](/durable-objects/api/id) corresponding to the name of a Durable Object instance.
8484

8585
#### Return value
8686

87-
A [`DurableObjectId`](../id) referring to an instance of a Durable Object class.
87+
A [`DurableObjectId`](/durable-objects/api/id) referring to an instance of a Durable Object class.
8888

8989
### `newUniqueId`
9090

@@ -99,23 +99,23 @@ const euId = env.MY_DURABLE_OBJECT.newUniqueId({ jurisdiction: "eu" });
9999

100100
:::note[`newUniqueId`]
101101

102-
IDs created by `newUniqueId` will result in lower latencies when getting a [`DurableObjectStub`](../stub) relative to [`idFromName`](../namespace/#idFromName).
102+
IDs created by `newUniqueId` will result in lower latencies when getting a [`DurableObjectStub`](/durable-objects/api/stub) relative to [`idFromName`](/durable-objects/api/namespace/#idfromname).
103103

104104
:::
105105

106106
#### Parameters
107107

108-
An optional object with the key `jurisdiction` and value of a [jurisdiction](../../reference/data-location/#restrict-durable-objects-to-a-jurisdiction) string.
108+
An optional object with the key `jurisdiction` and value of a [jurisdiction](durable-objects/reference/data-location/#restrict-durable-objects-to-a-jurisdiction) string.
109109

110110
#### Return value
111111

112-
A [`DurableObjectId`](../id) referring to an instance of the Durable Object class.
112+
A [`DurableObjectId`](/durable-objects/api/id) referring to an instance of the Durable Object class.
113113

114114
### `idFromString`
115115

116116
#### Description
117117

118-
`idFromString` creates a [`DurableObjectId`](../id) from a previously generated ID that has been converted to a string. This method ensures the ID is valid, for example, it checks that the ID consists of 64 hex digits.
118+
`idFromString` creates a [`DurableObjectId`](/durable-objects/api/id) from a previously generated ID that has been converted to a string. This method ensures the ID is valid, for example, it checks that the ID consists of 64 hex digits.
119119

120120
```js
121121
// Create a new unique ID
@@ -128,17 +128,17 @@ const id = env.MY_DURABLE_OBJECT.idFromString(session_id);
128128

129129
#### Parameters
130130

131-
The string corresponding to a [`DurableObjectId`](../id) previously generated either by `newUniqueId` or `idFromName`.
131+
The string corresponding to a [`DurableObjectId`](/durable-objects/api/id) previously generated either by `newUniqueId` or `idFromName`.
132132

133133
#### Return value
134134

135-
A [`DurableObjectId`](../id) referring to an instance of a Durable Object class.
135+
A [`DurableObjectId`](/durable-objects/api/id) referring to an instance of a Durable Object class.
136136

137137
### `get`
138138

139139
#### Description
140140

141-
`get` obtains a [`DurableObjectStub`](../stub) from a [`DurableObjectId`](../id) which can be used to invoke methods on a Durable Object instance.
141+
`get` obtains a [`DurableObjectStub`](/durable-objects/api/stub) from a [`DurableObjectId`](/durable-objects/api/id) which can be used to invoke methods on a Durable Object instance.
142142

143143
```js
144144
const id = env.MY_DURABLE_OBJECT.newUniqueId();
@@ -147,17 +147,17 @@ const stub = env.MY_DURABLE_OBJECT.get(id);
147147

148148
#### Parameters
149149

150-
A required [`DurableObjectId`](../id) and an optional object with the key `locationHint` and value of a [locationHint](../../reference/data-location/#provide-a-location-hint) string.
150+
A required [`DurableObjectId`](/durable-objects/api/id) and an optional object with the key `locationHint` and value of a [locationHint](durable-objects/reference/data-location/#provide-a-location-hint) string.
151151

152152
#### Return value
153153

154-
A [`DurableObjectStub`](../stub) referring to an instance of a Durable Object class.
154+
A [`DurableObjectStub`](/durable-objects/api/stub) referring to an instance of a Durable Object class.
155155

156156
### `jurisdiction`
157157

158158
#### Description
159159

160-
`jurisdiction` creates a subnamespace from a namespace where all Durable Object instance IDs and references created from that subnamespace will be restricted to the specified [jurisdiction](../../reference/data-location/#restrict-durable-objects-to-a-jurisdiction).
160+
`jurisdiction` creates a subnamespace from a namespace where all Durable Object instance IDs and references created from that subnamespace will be restricted to the specified [jurisdiction](durable-objects/reference/data-location/#restrict-durable-objects-to-a-jurisdiction).
161161

162162
```js
163163
const subnamespace = env.MY_DURABLE_OBJECT.jurisdiction("foo");
@@ -166,7 +166,7 @@ const euId = subnamespace.idFromName("foo");
166166

167167
#### Parameters
168168

169-
A required [jurisdiction](../../reference/data-location/#restrict-durable-objects-to-a-jurisdiction) string.
169+
A required [jurisdiction](durable-objects/reference/data-location/#restrict-durable-objects-to-a-jurisdiction) string.
170170

171171
#### Return value
172172

src/content/docs/durable-objects/api/stub.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ export default {
8989

9090
#### Description
9191

92-
`id` is a property of the `DurableObjectStub` corresponding to the [`DurableObjectId`](../id) used to create the stub.
92+
`id` is a property of the `DurableObjectStub` corresponding to the [`DurableObjectId`](/durable-objects/api/id) used to create the stub.
9393

9494
```js
9595
const id = env.MY_DURABLE_OBJECT.newUniqueId();
@@ -101,7 +101,7 @@ console.assert(id.equals(stub.id), "This should always be true");
101101

102102
#### Description
103103

104-
`name` is an optional property of a `DurableObjectStub`, which returns the name that was used to create the [`DurableObjectId`](../id) via [`DurableObjectNamespace::idFromName`](../namespace/#idfromname) which was then used to create the `DurableObjectStub`. This value is undefined if the [`DurableObjectId`](../id) used to create the `DurableObjectStub` was constructed using [`DurableObjectNamespace::newUniqueId`](../namespace/#newuniqueid).
104+
`name` is an optional property of a `DurableObjectStub`, which returns the name that was used to create the [`DurableObjectId`](/durable-objects/api/id) via [`DurableObjectNamespace::idFromName`](/durable-objects/api/namespace/#idfromname) which was then used to create the `DurableObjectStub`. This value is undefined if the [`DurableObjectId`](/durable-objects/api/id) used to create the `DurableObjectStub` was constructed using [`DurableObjectNamespace::newUniqueId`](/durable-objects/api/namespace/#newuniqueid).
105105

106106
```js
107107
const id = env.MY_DURABLE_OBJECT.idFromName("foo");

0 commit comments

Comments
 (0)