@logto/browser 2.2.2 → 2.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -4
- package/lib/index.d.ts +1 -1
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
# Logto JS Browser SDK
|
|
2
|
+
|
|
2
3
|
[](https://www.npmjs.com/package/@logto/browser)
|
|
3
4
|
[](https://github.com/logto-io/js/actions/workflows/main.yml)
|
|
4
5
|
[](https://app.codecov.io/gh/logto-io/js?branch=master)
|
|
5
6
|
|
|
6
|
-
The Logto JavaScript Browser SDK written in TypeScript.
|
|
7
|
+
The Logto JavaScript Browser SDK written in TypeScript.
|
|
8
|
+
|
|
9
|
+
Check out our [docs](https://docs.logto.io/sdk/vanilla-js/) for more information.
|
|
7
10
|
|
|
8
11
|
## Installation
|
|
9
12
|
|
|
@@ -32,12 +35,12 @@ As the name suggests, Logto browser SDK is the foundation of all Logto SDKs that
|
|
|
32
35
|
* Implements `Storage` by using browser `localStorage` and `sessionStorage`.
|
|
33
36
|
* Implements `navigate` method by using `window.location.href`.
|
|
34
37
|
|
|
35
|
-
Usually you are not expected to use it directly in your application, but instead choosing a framework specific SDK that built on top of it. We have already released a set of official SDKs to accelerate your integration. [Check this out](https://docs.logto.io/
|
|
38
|
+
Usually you are not expected to use it directly in your application, but instead choosing a framework specific SDK that built on top of it. We have already released a set of official SDKs to accelerate your integration. [Check this out](https://docs.logto.io/sdk/) and get started!
|
|
36
39
|
|
|
37
|
-
If Logto does not support your front-end framework and you want to create your own SDK from scratch, we recommend checking out the SDK
|
|
40
|
+
If Logto does not support your front-end framework and you want to create your own SDK from scratch, we recommend checking out the [SDK convention](https://docs.logto.io/docs/references/sdk-convention/) first. You can also refer to our [React SDK](https://github.com/logto-io/js/tree/master/packages/react) and [Vue SDK](https://github.com/logto-io/js/tree/master/packages/vue) to learn more about the implementation details.
|
|
38
41
|
|
|
39
42
|
## Resources
|
|
40
43
|
|
|
41
44
|
[](https://logto.io/)
|
|
42
|
-
[](https://docs.logto.io/
|
|
45
|
+
[](https://docs.logto.io/)
|
|
43
46
|
[](https://discord.gg/UEPaF3j5e6)
|
package/lib/index.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import type { LogtoConfig } from '@logto/client';
|
|
|
2
2
|
import BaseClient from '@logto/client';
|
|
3
3
|
export { createRequester, default as BaseClient } from '@logto/client';
|
|
4
4
|
export { generateCodeChallenge, generateCodeVerifier, generateState } from './utils/generators.js';
|
|
5
|
-
export type { IdTokenClaims, LogtoErrorCode, LogtoConfig, LogtoClientErrorCode, UserInfoResponse, InteractionMode, ClientAdapter, } from '@logto/client';
|
|
5
|
+
export type { IdTokenClaims, LogtoErrorCode, LogtoConfig, LogtoClientErrorCode, UserInfoResponse, InteractionMode, ClientAdapter, SignInOptions, } from '@logto/client';
|
|
6
6
|
export { LogtoError, LogtoRequestError, LogtoClientError, OidcError, Prompt, ReservedScope, ReservedResource, UserScope, organizationUrnPrefix, buildOrganizationUrn, getOrganizationIdFromUrn, PersistKey, } from '@logto/client';
|
|
7
7
|
export default class LogtoClient extends BaseClient {
|
|
8
8
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@logto/browser",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.4",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./lib/index.cjs",
|
|
6
6
|
"module": "./lib/index.js",
|
|
@@ -21,9 +21,9 @@
|
|
|
21
21
|
"directory": "packages/browser"
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@logto/client": "^2.3.3",
|
|
25
24
|
"@silverhand/essentials": "^2.8.7",
|
|
26
|
-
"js-base64": "^3.7.4"
|
|
25
|
+
"js-base64": "^3.7.4",
|
|
26
|
+
"@logto/client": "^2.6.0"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
29
29
|
"@silverhand/eslint-config": "^5.0.0",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"lint-staged": "^15.0.0",
|
|
39
39
|
"prettier": "^3.0.0",
|
|
40
40
|
"text-encoder": "^0.0.4",
|
|
41
|
-
"typescript": "^5.
|
|
41
|
+
"typescript": "^5.3.3"
|
|
42
42
|
},
|
|
43
43
|
"eslintConfig": {
|
|
44
44
|
"extends": "@silverhand"
|