@thor-commerce/app-bridge-react 0.1.0 → 0.1.2

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 (2) hide show
  1. package/README.md +11 -3
  2. package/package.json +31 -2
package/README.md CHANGED
@@ -1,17 +1,19 @@
1
- # `@thorcommerce/app-bridge-react`
1
+ # `@thor-commerce/app-bridge-react`
2
2
 
3
3
  Communication bridge between embedded apps and the Thor Commerce dashboard.
4
4
 
5
+ Repository link: [thor-email-app](https://github.com/thor-commerce/thor-email-app)
6
+
5
7
  ## Installation
6
8
 
7
9
  ```bash
8
- npm install @thorcommerce/app-bridge-react
10
+ npm install @thor-commerce/app-bridge-react
9
11
  ```
10
12
 
11
13
  ## Usage
12
14
 
13
15
  ```ts
14
- import { createAppBridge } from "@thorcommerce/app-bridge-react";
16
+ import { createAppBridge } from "@thor-commerce/app-bridge-react";
15
17
 
16
18
  const bridge = createAppBridge({
17
19
  source: "embedded-app",
@@ -38,3 +40,9 @@ bridge.on("navigation:update", (message) => {
38
40
  - `bridge.onRequest(type, handler)` registers a request handler that can reply with a value or promise.
39
41
  - `bridge.setTargetWindow(window)` updates the destination window after construction.
40
42
  - `bridge.destroy()` removes listeners and rejects pending requests.
43
+
44
+ ## Releases
45
+
46
+ - Publishing is handled by semantic-release from `main`.
47
+ - Use Conventional Commits so releases are created automatically: `fix:` for patch, `feat:` for minor, and `BREAKING CHANGE:` for major.
48
+ - npm publishing uses npm Trusted Publisher from GitHub Actions; no `NPM_TOKEN` is required.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thor-commerce/app-bridge-react",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "description": "Communication bridge between embedded apps and the Thor Commerce dashboard",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",
@@ -19,19 +19,48 @@
19
19
  "scripts": {
20
20
  "build": "tsup",
21
21
  "dev": "tsup --watch",
22
+ "release": "semantic-release",
22
23
  "test": "tsx --test test/*.test.ts",
23
24
  "typecheck": "tsc --noEmit",
24
25
  "prepublishOnly": "npm run build"
25
26
  },
27
+ "release": {
28
+ "branches": [
29
+ "main"
30
+ ],
31
+ "tagFormat": "v${version}",
32
+ "plugins": [
33
+ "@semantic-release/commit-analyzer",
34
+ "@semantic-release/release-notes-generator",
35
+ [
36
+ "@semantic-release/npm",
37
+ {
38
+ "npmPublish": true
39
+ }
40
+ ]
41
+ ]
42
+ },
26
43
  "devDependencies": {
44
+ "@semantic-release/commit-analyzer": "^13.0.1",
45
+ "@semantic-release/npm": "^13.1.5",
46
+ "@semantic-release/release-notes-generator": "^14.1.0",
27
47
  "@types/node": "^25.5.0",
48
+ "semantic-release": "^25.0.3",
28
49
  "tsup": "^8.0.0",
29
50
  "tsx": "^4.21.0",
30
51
  "typescript": "^5.5.0"
31
52
  },
32
53
  "license": "MIT",
33
54
  "repository": {
34
- "type": "git"
55
+ "type": "git",
56
+ "url": "git+https://github.com/thor-commerce/thor-app-bridge.git"
57
+ },
58
+ "homepage": "https://github.com/thor-commerce/thor-email-app",
59
+ "bugs": {
60
+ "url": "https://github.com/thor-commerce/thor-app-bridge/issues"
61
+ },
62
+ "publishConfig": {
63
+ "access": "public"
35
64
  },
36
65
  "keywords": [
37
66
  "thor-commerce",