@simpoobusiness/sdk 1.0.15 → 1.0.17

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 +3 -8
  2. package/package.json +4 -11
package/README.md CHANGED
@@ -12,10 +12,6 @@ No npm installation is required.
12
12
  Add these tags inside your `<head>` or before `</body>`:
13
13
 
14
14
  ```html
15
- <link
16
- rel="stylesheet"
17
- href="https://unpkg.com/@simpoobusiness/sdk/dist/simpoo-sdk.css"
18
- />
19
15
  <script src="https://unpkg.com/@simpoobusiness/sdk/dist/simpoo-sdk.js"></script>
20
16
  ```
21
17
 
@@ -26,6 +22,7 @@ Add a container where you want the inventory widget to appear:
26
22
  ```
27
23
 
28
24
  Then initialize and render the widget:
25
+ Preferrably before the the closing tag `</body> of the page`
29
26
 
30
27
  ```html
31
28
  <script>
@@ -63,12 +60,13 @@ SimpooSDK.init({ apiKey: "12345" });
63
60
 
64
61
  ---
65
62
 
66
- ### **SimpooSDK.renderInventory(containerSelector)**
63
+ ### **SimpooSDK.renderWidget(widget_name, selector)**
67
64
 
68
65
  Render the inventory widget in a container.
69
66
 
70
67
  **Parameters:**
71
68
 
69
+ - `widget_name` (string) – name for the inventory widget.
72
70
  - `selector` (string) – CSS selector for the container.
73
71
 
74
72
  **Example:**
@@ -83,9 +81,6 @@ SimpooSDK.renderWidget("inventory", "#inventory-widget");
83
81
 
84
82
  - **Widget not rendering?**
85
83
  Ensure the container `<div>` exists and the selector matches.
86
- - **No styles applied?**
87
- Make sure `<link rel="stylesheet" href="https://cdn.example.com/simpoo-sdk.css">` is included.
88
- <!-- *(If missing, the SDK will auto-inject CSS.)* -->
89
84
 
90
85
  ---
91
86
 
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "1.0.15",
6
+ "version": "1.0.17",
7
7
  "types": "dist/index.d.ts",
8
8
  "unpkg": "dist/simpoo-sdk.js",
9
9
  "jsdelivr": "dist/simpoo-sdk.js",
@@ -19,25 +19,20 @@
19
19
  "author": "",
20
20
  "license": "MIT",
21
21
  "description": "Simpoo SDK for embedding simpooBusiness inventory widgets into any web app",
22
-
23
- "scripts": {
22
+ "scripts": {
24
23
  "clean": "rimraf dist",
25
24
  "typecheck": "tsc --noEmit",
26
25
  "build": "npm run clean && npm run build:types && npm run build:bundle",
27
26
  "build:bundle": "cross-env NODE_ENV=production rollup -c --bundleConfigAsCjs",
28
27
  "docs": "typedoc --out docs src/embed.tsx",
29
28
  "build:watch": "cross-env NODE_ENV=production rollup -c --bundleConfigAsCjs -w ",
30
- "dev": "npm run build:watch",
29
+ "dev": "npm run build:watch",
31
30
  "build:types": "tsc --emitDeclarationOnly --declaration --declarationDir dist --project tsconfig.build.json",
32
31
  "publish:npm": "npm publish --access public"
33
32
  },
34
-
35
- "peerDependencies": {
36
- },
33
+ "peerDependencies": {},
37
34
  "devDependencies": {
38
-
39
35
  "@rollup/plugin-commonjs": "^28.0.6",
40
-
41
36
  "@rollup/plugin-node-resolve": "^16.0.1",
42
37
  "@rollup/plugin-replace": "^6.0.2",
43
38
  "@rollup/plugin-typescript": "^12.1.4",
@@ -53,9 +48,7 @@
53
48
  "react-dom": "^19.1.1",
54
49
  "rimraf": "^5.0.10",
55
50
  "rollup": "^4.45.1",
56
-
57
51
  "rollup-plugin-node-polyfills": "^0.2.1",
58
-
59
52
  "rollup-plugin-postcss": "^4.0.2",
60
53
  "rollup-plugin-terser": "^7.0.2",
61
54
  "tailwindcss": "^4.1.11",