@looker/extension-sdk 21.18.0 → 22.0.0

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.
Files changed (3) hide show
  1. package/CHANGELOG.md +53 -0
  2. package/README.md +16 -16
  3. package/package.json +6 -6
package/CHANGELOG.md CHANGED
@@ -5,6 +5,59 @@ All notable changes to this project will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [22.0.0](https://www.github.com/looker-open-source/sdk-codegen/compare/extension-sdk-v21.20.1...extension-sdk-v22.0.0) (2022-02-14)
9
+
10
+
11
+ ### ⚠ BREAKING CHANGES
12
+
13
+ * SDK support for 22.0
14
+
15
+ ### Features
16
+
17
+ * SDK support for 22.0 ([5f9930c](https://www.github.com/looker-open-source/sdk-codegen/commit/5f9930c0b0f7bde59f0b9b47f882ae1f3ff9e490))
18
+
19
+ ### [21.20.1](https://www.github.com/looker-open-source/sdk-codegen/compare/extension-sdk-v21.20.0...extension-sdk-v21.20.1) (2022-01-27)
20
+
21
+
22
+ ### Dependencies
23
+
24
+ * The following workspace dependencies were updated
25
+ * dependencies
26
+ * @looker/sdk bumped from ^21.20.0 to ^21.20.1
27
+
28
+ ## [21.20.1](https://www.github.com/looker-open-source/sdk-codegen/compare/extension-sdk-v21.20.0...extension-sdk-v21.20.1) (2021-12-20)
29
+
30
+ ### Dependencies
31
+
32
+ * The following workspace dependencies were updated
33
+ * dependencies
34
+ * @looker/sdk-rtl bumped from ^21.2.0 to ^21.3.1
35
+
36
+ ## [21.20.0](https://www.github.com/looker-open-source/sdk-codegen/compare/extension-sdk-v21.18.1...extension-sdk-v21.20.0) (2021-11-10)
37
+
38
+
39
+ ### Features
40
+
41
+ * create @looker/extension-utils ([#886](https://www.github.com/looker-open-source/sdk-codegen/issues/886)) ([9d1720d](https://www.github.com/looker-open-source/sdk-codegen/commit/9d1720d9a4cec00c45195dd9c716d9a2a929264f))
42
+
43
+
44
+ ### Dependencies
45
+
46
+ * The following workspace dependencies were updated
47
+ * dependencies
48
+ * @looker/sdk bumped from ^21.18.1 to ^21.20.0
49
+ * @looker/sdk-rtl bumped from ^21.1.1 to ^21.2.0
50
+
51
+ ### [21.18.1](https://www.github.com/looker-open-source/sdk-codegen/compare/extension-sdk-v21.18.0...extension-sdk-v21.18.1) (2021-10-27)
52
+
53
+
54
+ ### Dependencies
55
+
56
+ * The following workspace dependencies were updated
57
+ * dependencies
58
+ * @looker/sdk bumped from ^21.18.0 to ^21.18.1
59
+ * @looker/sdk-rtl bumped from ^21.1.0 to ^21.1.1
60
+
8
61
  ## [21.18.0](https://www.github.com/looker-open-source/sdk-codegen/compare/extension-sdk-v21.16.0...extension-sdk-v21.18.0) (2021-10-24)
9
62
 
10
63
 
package/README.md CHANGED
@@ -6,7 +6,7 @@ A Looker extension is JavaScript code that code that runs inside of the Looker U
6
6
 
7
7
  Extensions are implemented as a sandboxed `<iframe>` and communication with Looker is accomplished through this SDK. Internally, the SDK will translate function calls into messages passed safely across the iframe boundary. The specific format of those messages is considered private, and this SDK is the only supported interface for interacting with the host from an extension.
8
8
 
9
- [React bindings for extensions](https://github.com/looker-open-source/extension-template-react) are also available, as well as [a template project in React and TypeScript to help you get started](https://github.com/looker-open-source/extension-template-react).
9
+ [React bindings for extensions](https://github.com/looker-open-source/sdk-codegen/tree/main/packages/extension-sdk-react) are also available, as well as [examples to help you get started](https://github.com/looker-open-source/extension-examples). The [create looker extension utility](https://docs.looker.com/data-modeling/extension-framework/installing-extension#generating_the_extension_template_files) is also available to help you get started quickly.
10
10
 
11
11
  ## Installation
12
12
 
@@ -29,21 +29,21 @@ npm install @looker/extension-sdk
29
29
  The Extension SDK must establish a connection with its host before further functionality will be available.
30
30
 
31
31
  ```ts
32
- import { LookerExtensionSDK, connectExtensionHost } from '@looker/extension-sdk'
33
- import { Looker40SDK } from '@looker/sdk'
34
-
35
- let extensionSDK
36
- let coreSDK
37
-
38
- // Establish connection
39
- connectExtensionHost()
40
- .then((host) => {
41
- // This `extensionSDK` can perform extension-specific actions
42
- extensionSDK = host
43
- // This `coreSDK` is an automatically credentialed variant of the standard Looker Core SDK for performing API calls
44
- coreSDK = LookerExtensionSDK.create40Client(extensionSDK)
45
- })
46
- .catch((error) => console.error())
32
+ import {
33
+ connectExtensionHost,
34
+ LookerExtensionSDK40,
35
+ } from '@looker/extension-sdk'
36
+
37
+ ;(async () => {
38
+ // This `extensionSDK` can perform extension-specific actions
39
+ const extensionSdk = await connectExtensionHost()
40
+ // This `coreSDK` is an automatically credentialed variant of the standard Looker Core SDK for performing API calls
41
+ const coreSDK = LookerExtensionSDK40.createClient(extensionSdk)
42
+ const result = await sdk40.me()
43
+ const name = result.ok ? result.value.display_name : 'Unknown'
44
+
45
+ // DO OTHER THINGS
46
+ })()
47
47
  ```
48
48
 
49
49
  The following create methods are also available
package/package.json CHANGED
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "@looker/extension-sdk",
3
- "version": "21.18.0",
3
+ "version": "22.0.0",
4
4
  "description": "Looker Extension SDK",
5
5
  "main": "lib/index.js",
6
6
  "module": "lib/esm/index.js",
7
- "sideEffects": "false",
7
+ "sideEffects": false,
8
8
  "typings": "lib/index.d.ts",
9
9
  "files": [
10
10
  "lib"
@@ -16,7 +16,7 @@
16
16
  "repository": {
17
17
  "type": "git",
18
18
  "url": "git+https://github.com/looker-open-source/sdk-codegen.git",
19
- "directory": "packages/sdk-rtl"
19
+ "directory": "packages/extension-sdk"
20
20
  },
21
21
  "author": "Looker",
22
22
  "license": "MIT",
@@ -40,8 +40,8 @@
40
40
  },
41
41
  "dependencies": {
42
42
  "@looker/chatty": "^2.3.0",
43
- "@looker/sdk": "^21.18.0",
44
- "@looker/sdk-rtl": "^21.1.0",
43
+ "@looker/sdk": "^22.0.0",
44
+ "@looker/sdk-rtl": "^21.3.2",
45
45
  "deepmerge": "^4.2.2",
46
46
  "readable-stream": "^3.4.0",
47
47
  "request": "^2.88.0",
@@ -52,5 +52,5 @@
52
52
  "Looker",
53
53
  "extension-sdk"
54
54
  ],
55
- "gitHead": "59124bd94f97f28a7ce80930f94d7562bba912fc"
55
+ "gitHead": "f8867339965baf85c26b3beaee8e4621e3cff3a8"
56
56
  }