Skip to content

Commit

Permalink
docs(useConst): rename to useConstant
Browse files Browse the repository at this point in the history
  • Loading branch information
PatrickJS committed May 17, 2024
1 parent 861f53b commit ad15e34
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
12 changes: 6 additions & 6 deletions packages/docs/src/routes/api/qwik/api.json
Original file line number Diff line number Diff line change
Expand Up @@ -3039,18 +3039,18 @@
"mdFile": "qwik.usecomputedqrl.md"
},
{
"name": "useConst",
"id": "useconst",
"name": "useConstant",
"id": "useconstant",
"hierarchy": [
{
"name": "useConst",
"id": "useconst"
"name": "useConstant",
"id": "useconstant"
}
],
"kind": "Function",
"content": "Stores a value which is retained for the lifetime of the component.\n\nIf the value is a function, the function is invoked to calculate the actual value.\n\n\n```typescript\nuseConst: <T>(value: (() => T) | T) => T\n```\n\n\n<table><thead><tr><th>\n\nParameter\n\n\n</th><th>\n\nType\n\n\n</th><th>\n\nDescription\n\n\n</th></tr></thead>\n<tbody><tr><td>\n\nvalue\n\n\n</td><td>\n\n(() =&gt; T) \\| T\n\n\n</td><td>\n\n\n</td></tr>\n</tbody></table>\n**Returns:**\n\nT",
"content": "Stores a value which is retained for the lifetime of the component.\n\nIf the value is a function, the function is invoked to calculate the actual value.\n\n\n```typescript\nuseConstant: <T>(value: (() => T) | T) => T\n```\n\n\n<table><thead><tr><th>\n\nParameter\n\n\n</th><th>\n\nType\n\n\n</th><th>\n\nDescription\n\n\n</th></tr></thead>\n<tbody><tr><td>\n\nvalue\n\n\n</td><td>\n\n(() =&gt; T) \\| T\n\n\n</td><td>\n\n\n</td></tr>\n</tbody></table>\n**Returns:**\n\nT",
"editUrl": "https://github.com/QwikDev/qwik/tree/main/packages/qwik/src/core/use/use-signal.ts",
"mdFile": "qwik.useconst.md"
"mdFile": "qwik.useconstant.md"
},
{
"name": "useContext",
Expand Down
4 changes: 2 additions & 2 deletions packages/docs/src/routes/api/qwik/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -10183,14 +10183,14 @@ qrl
[Edit this section](https://github.com/QwikDev/qwik/tree/main/packages/qwik/src/core/use/use-task.ts)
## useConst
## useConstant
Stores a value which is retained for the lifetime of the component.
If the value is a function, the function is invoked to calculate the actual value.
```typescript
useConst: <T>(value: (() => T) | T) => T;
useConstant: <T>(value: (() => T) | T) => T;
```
<table><thead><tr><th>
Expand Down
2 changes: 1 addition & 1 deletion packages/qwik/src/core/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -1628,7 +1628,7 @@ export const useComputed$: <T>(qrl: ComputedFn<T>) => Signal<Awaited<T>>;
export const useComputedQrl: <T>(qrl: QRL<ComputedFn<T>>) => Signal<Awaited<T>>;

// @public
export const useConst: <T>(value: (() => T) | T) => T;
export const useConstant: <T>(value: (() => T) | T) => T;

// Warning: (ae-forgotten-export) The symbol "UseContext" needs to be exported by the entry point index.d.ts
//
Expand Down

0 comments on commit ad15e34

Please sign in to comment.