-
-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix!: move useSession hook to its own entry point
- Loading branch information
1 parent
d95a4ed
commit 4809803
Showing
14 changed files
with
774 additions
and
78 deletions.
There are no files selected for viewing
228 changes: 228 additions & 0 deletions
228
packages/elements-react/api-report/elements-react-client.api.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,228 @@ | ||
{ | ||
"metadata": { | ||
"toolPackage": "@microsoft/api-extractor", | ||
"toolVersion": "7.47.9", | ||
"schemaVersion": 1011, | ||
"oldestForwardsCompatibleVersion": 1001, | ||
"tsdocConfig": { | ||
"$schema": "https://developer.microsoft.com/json-schemas/tsdoc/v0/tsdoc.schema.json", | ||
"noStandardTags": true, | ||
"tagDefinitions": [ | ||
{ | ||
"tagName": "@alpha", | ||
"syntaxKind": "modifier" | ||
}, | ||
{ | ||
"tagName": "@beta", | ||
"syntaxKind": "modifier" | ||
}, | ||
{ | ||
"tagName": "@defaultValue", | ||
"syntaxKind": "block" | ||
}, | ||
{ | ||
"tagName": "@decorator", | ||
"syntaxKind": "block", | ||
"allowMultiple": true | ||
}, | ||
{ | ||
"tagName": "@deprecated", | ||
"syntaxKind": "block" | ||
}, | ||
{ | ||
"tagName": "@eventProperty", | ||
"syntaxKind": "modifier" | ||
}, | ||
{ | ||
"tagName": "@example", | ||
"syntaxKind": "block", | ||
"allowMultiple": true | ||
}, | ||
{ | ||
"tagName": "@experimental", | ||
"syntaxKind": "modifier" | ||
}, | ||
{ | ||
"tagName": "@inheritDoc", | ||
"syntaxKind": "inline" | ||
}, | ||
{ | ||
"tagName": "@internal", | ||
"syntaxKind": "modifier" | ||
}, | ||
{ | ||
"tagName": "@label", | ||
"syntaxKind": "inline" | ||
}, | ||
{ | ||
"tagName": "@link", | ||
"syntaxKind": "inline", | ||
"allowMultiple": true | ||
}, | ||
{ | ||
"tagName": "@override", | ||
"syntaxKind": "modifier" | ||
}, | ||
{ | ||
"tagName": "@packageDocumentation", | ||
"syntaxKind": "modifier" | ||
}, | ||
{ | ||
"tagName": "@param", | ||
"syntaxKind": "block", | ||
"allowMultiple": true | ||
}, | ||
{ | ||
"tagName": "@privateRemarks", | ||
"syntaxKind": "block" | ||
}, | ||
{ | ||
"tagName": "@public", | ||
"syntaxKind": "modifier" | ||
}, | ||
{ | ||
"tagName": "@readonly", | ||
"syntaxKind": "modifier" | ||
}, | ||
{ | ||
"tagName": "@remarks", | ||
"syntaxKind": "block" | ||
}, | ||
{ | ||
"tagName": "@returns", | ||
"syntaxKind": "block" | ||
}, | ||
{ | ||
"tagName": "@sealed", | ||
"syntaxKind": "modifier" | ||
}, | ||
{ | ||
"tagName": "@see", | ||
"syntaxKind": "block" | ||
}, | ||
{ | ||
"tagName": "@throws", | ||
"syntaxKind": "block", | ||
"allowMultiple": true | ||
}, | ||
{ | ||
"tagName": "@typeParam", | ||
"syntaxKind": "block", | ||
"allowMultiple": true | ||
}, | ||
{ | ||
"tagName": "@virtual", | ||
"syntaxKind": "modifier" | ||
}, | ||
{ | ||
"tagName": "@betaDocumentation", | ||
"syntaxKind": "modifier" | ||
}, | ||
{ | ||
"tagName": "@internalRemarks", | ||
"syntaxKind": "block" | ||
}, | ||
{ | ||
"tagName": "@preapproved", | ||
"syntaxKind": "modifier" | ||
} | ||
], | ||
"supportForTags": { | ||
"@alpha": true, | ||
"@beta": true, | ||
"@defaultValue": true, | ||
"@decorator": true, | ||
"@deprecated": true, | ||
"@eventProperty": true, | ||
"@example": true, | ||
"@experimental": true, | ||
"@inheritDoc": true, | ||
"@internal": true, | ||
"@label": true, | ||
"@link": true, | ||
"@override": true, | ||
"@packageDocumentation": true, | ||
"@param": true, | ||
"@privateRemarks": true, | ||
"@public": true, | ||
"@readonly": true, | ||
"@remarks": true, | ||
"@returns": true, | ||
"@sealed": true, | ||
"@see": true, | ||
"@throws": true, | ||
"@typeParam": true, | ||
"@virtual": true, | ||
"@betaDocumentation": true, | ||
"@internalRemarks": true, | ||
"@preapproved": true | ||
}, | ||
"reportUnsupportedHtmlElements": false | ||
} | ||
}, | ||
"kind": "Package", | ||
"canonicalReference": "@ory/elements-react!", | ||
"docComment": "", | ||
"name": "@ory/elements-react", | ||
"preserveMemberOrder": false, | ||
"members": [ | ||
{ | ||
"kind": "EntryPoint", | ||
"canonicalReference": "@ory/elements-react!", | ||
"name": "", | ||
"preserveMemberOrder": false, | ||
"members": [ | ||
{ | ||
"kind": "Function", | ||
"canonicalReference": "@ory/elements-react!useSession:function(1)", | ||
"docComment": "/**\n * A hook to get the current session from the Ory Network.\n *\n * Usage:\n * ```ts\n * const { session, error, isLoading } = useSession()\n * ```\n *\n * @returns The current session, error and loading state.\n */\n", | ||
"excerptTokens": [ | ||
{ | ||
"kind": "Content", | ||
"text": "useSession: (config?: " | ||
}, | ||
{ | ||
"kind": "Content", | ||
"text": "{\n sdk: {\n url: string;\n };\n}" | ||
}, | ||
{ | ||
"kind": "Content", | ||
"text": ") => " | ||
}, | ||
{ | ||
"kind": "Content", | ||
"text": "{\n session: " | ||
}, | ||
{ | ||
"kind": "Reference", | ||
"text": "Session", | ||
"canonicalReference": "@ory/client-fetch!Session:interface" | ||
}, | ||
{ | ||
"kind": "Content", | ||
"text": " | undefined;\n error: string | undefined;\n isLoading: boolean;\n}" | ||
} | ||
], | ||
"fileUrlPath": "dist/client/useSession.d.ts", | ||
"returnTypeTokenRange": { | ||
"startIndex": 3, | ||
"endIndex": 6 | ||
}, | ||
"releaseTag": "Public", | ||
"overloadIndex": 1, | ||
"parameters": [ | ||
{ | ||
"parameterName": "config", | ||
"parameterTypeTokenRange": { | ||
"startIndex": 1, | ||
"endIndex": 2 | ||
}, | ||
"isOptional": true | ||
} | ||
], | ||
"name": "useSession" | ||
} | ||
] | ||
} | ||
] | ||
} |
22 changes: 22 additions & 0 deletions
22
packages/elements-react/api-report/elements-react-client.api.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
## API Report File for "@ory/elements-react" | ||
|
||
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). | ||
```ts | ||
|
||
import { Session } from '@ory/client-fetch'; | ||
|
||
// @public | ||
export const useSession: (config?: { | ||
sdk: { | ||
url: string; | ||
}; | ||
}) => { | ||
session: Session | undefined; | ||
error: string | undefined; | ||
isLoading: boolean; | ||
}; | ||
|
||
// (No @packageDocumentation comment for this package) | ||
|
||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.