@looker/extension-sdk 21.16.0 → 21.20.1

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 +52 -1
  2. package/README.md +16 -16
  3. package/package.json +6 -6
package/CHANGELOG.md CHANGED
@@ -5,6 +5,57 @@ 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
+ ### [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)
9
+
10
+
11
+ ### Dependencies
12
+
13
+ * The following workspace dependencies were updated
14
+ * dependencies
15
+ * @looker/sdk bumped from ^21.20.0 to ^21.20.1
16
+
17
+ ## [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)
18
+
19
+ ### Dependencies
20
+
21
+ * The following workspace dependencies were updated
22
+ * dependencies
23
+ * @looker/sdk-rtl bumped from ^21.2.0 to ^21.3.1
24
+
25
+ ## [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)
26
+
27
+
28
+ ### Features
29
+
30
+ * 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))
31
+
32
+
33
+ ### Dependencies
34
+
35
+ * The following workspace dependencies were updated
36
+ * dependencies
37
+ * @looker/sdk bumped from ^21.18.1 to ^21.20.0
38
+ * @looker/sdk-rtl bumped from ^21.1.1 to ^21.2.0
39
+
40
+ ### [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)
41
+
42
+
43
+ ### Dependencies
44
+
45
+ * The following workspace dependencies were updated
46
+ * dependencies
47
+ * @looker/sdk bumped from ^21.18.0 to ^21.18.1
48
+ * @looker/sdk-rtl bumped from ^21.1.0 to ^21.1.1
49
+
50
+ ## [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)
51
+
52
+
53
+ ### Dependencies
54
+
55
+ * The following workspace dependencies were updated
56
+ * dependencies
57
+ * @looker/sdk bumped from ^21.16.0 to ^21.18.0
58
+
8
59
  ## [21.16.0](https://www.github.com/looker-open-source/sdk-codegen/compare/extension-sdk-v21.14.0...extension-sdk-v21.16.0) (2021-10-19)
9
60
 
10
61
 
@@ -196,4 +247,4 @@ in extension builds.
196
247
 
197
248
  ## [21.0.5]
198
249
 
199
- Moved to the /looker-open-source/sdk-codegen github repository.
250
+ Moved to the /looker-open-source/sdk-codegen github repository.
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.16.0",
3
+ "version": "21.20.1",
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.16.0",
44
- "@looker/sdk-rtl": "^21.1.0",
43
+ "@looker/sdk": "^21.20.1",
44
+ "@looker/sdk-rtl": "^21.3.1",
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": "295c2ed60f9e41c3664d8505ebc1f2c2b5a1fbbc"
55
+ "gitHead": "86e7173f6c9e7b50f6b6474bafdf5780183152db"
56
56
  }