@datapos/datapos-shared 0.3.37 → 0.3.40
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 +46 -18
- package/package.json +11 -8
- /package/{LICENSE.md → LICENSE} +0 -0
package/README.md
CHANGED
|
@@ -1,27 +1,55 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Data Positioning Shared Library
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
[](https://www.npmjs.com/package/@datapos/datapos-shared)
|
|
4
|
+
[](./LICENSE)
|
|
5
|
+
[](#)
|
|
6
|
+
|
|
7
|
+
A TypeScript library containing common declarations and utilities used across other Data Positioning repositories.
|
|
4
8
|
|
|
5
9
|
## Installation
|
|
6
10
|
|
|
11
|
+
Install as a development (dev) dependency:
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
npm install --save-dev @datapos/datapos-shared
|
|
7
15
|
```
|
|
8
|
-
|
|
16
|
+
|
|
17
|
+
## Usage
|
|
18
|
+
|
|
19
|
+
Import the library in your TypeScript project:
|
|
20
|
+
|
|
21
|
+
```ts
|
|
22
|
+
import { type ConnectorConfig, getComponentStatus } from '@datapos/datapos-shared';
|
|
23
|
+
|
|
24
|
+
// Example type usage.
|
|
25
|
+
let connectorConfig: ConnectorConfig;
|
|
26
|
+
|
|
27
|
+
// Example function usage.
|
|
28
|
+
getComponentStatus('alpha');
|
|
9
29
|
```
|
|
10
30
|
|
|
31
|
+
> ⚠️ This library is intended for TypeScript projects.
|
|
32
|
+
|
|
11
33
|
## Repository Management Commands
|
|
12
34
|
|
|
13
|
-
The
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
|
17
|
-
|
|
|
18
|
-
|
|
|
19
|
-
|
|
|
20
|
-
|
|
|
21
|
-
|
|
|
22
|
-
|
|
|
23
|
-
|
|
|
24
|
-
|
|
|
25
|
-
|
|
|
26
|
-
|
|
|
27
|
-
|
|
|
35
|
+
The table below lists the repository management commands available in this project.
|
|
36
|
+
For detailed implementation, see the `scripts` section in `package.json`.
|
|
37
|
+
|
|
38
|
+
| Name | Key Code | Notes |
|
|
39
|
+
| ------------------ | ---------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
40
|
+
| audit | alt+ctrl+shift+a | Audit the project's dependencies for known security vulnerabilities. |
|
|
41
|
+
| build | alt+ctrl+shift+b | Build the package using Vite. |
|
|
42
|
+
| check | alt+ctrl+shift+c | List outdated dependencies. |
|
|
43
|
+
| document | alt+ctrl+shift+d | Identify licenses of the project's production and peer dependencies. |
|
|
44
|
+
| format | alt+ctrl+shift+f | NOT implemented. |
|
|
45
|
+
| lint | alt+ctrl+shift+l | Check the code for errors and enforce coding style rules. |
|
|
46
|
+
| publishToNPM | alt+ctrl+shift+n | Publishes the package to the [npm](https://www.npmjs.com/) registry. This action will publish the last synchronised version. For first-time publish, use `npm publish`. |
|
|
47
|
+
| release | alt+ctrl+shift+r | Synchronise local repository with the main GitHub repository and publish to [npm](https://www.npmjs.com/). |
|
|
48
|
+
| syncWithGitHub | alt+ctrl+shift+s | Synchronise local repository with the main GitHub repository. |
|
|
49
|
+
| test | alt+ctrl+shift+l | NOT implemented. |
|
|
50
|
+
| updateDependencies | alt+ctrl+shift+l | Install the latest version of outdated Data Positioning packages. |
|
|
51
|
+
| |
|
|
52
|
+
|
|
53
|
+
## License
|
|
54
|
+
|
|
55
|
+
[MIT](./LICENSE) © 2026 Data Positioning Pty Ltd
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@datapos/datapos-shared",
|
|
3
3
|
"license": "MIT",
|
|
4
4
|
"private": false,
|
|
5
|
-
"version": "0.3.
|
|
5
|
+
"version": "0.3.40",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"files": [
|
|
8
8
|
"dist"
|
|
@@ -17,25 +17,28 @@
|
|
|
17
17
|
"types": "./dist/types/src/index.d.ts",
|
|
18
18
|
"devDependencies": {
|
|
19
19
|
"@datapos/datapos-development": "^0.3.18",
|
|
20
|
-
"@types/node": "^24.5.
|
|
20
|
+
"@types/node": "^24.5.2",
|
|
21
21
|
"@typescript-eslint/eslint-plugin": "^8.44.0",
|
|
22
22
|
"@typescript-eslint/parser": "^8.44.0",
|
|
23
23
|
"csv-parse": "^6.1.0",
|
|
24
|
-
"eslint": "^9.
|
|
24
|
+
"eslint": "^9.36.0",
|
|
25
25
|
"eslint-plugin-import": "^2.32.0",
|
|
26
|
+
"license-report": "^6.8.0",
|
|
27
|
+
"license-report-check": "^0.1.2",
|
|
28
|
+
"npm-check-updates": "^18.3.0",
|
|
26
29
|
"prettier": "^3.6.2",
|
|
27
30
|
"typescript": "^5.9.2",
|
|
28
|
-
"vite": "^7.1.
|
|
31
|
+
"vite": "^7.1.6",
|
|
29
32
|
"vite-plugin-dts": "^4.5.4"
|
|
30
33
|
},
|
|
31
34
|
"scripts": {
|
|
32
35
|
"audit": "npm audit",
|
|
33
|
-
"build": "
|
|
36
|
+
"build": "vite build",
|
|
34
37
|
"bumpVersion": "node -e \"require('@datapos/datapos-development').bumpVersion()\"",
|
|
35
|
-
"check": "
|
|
36
|
-
"document": "
|
|
38
|
+
"check": "npm outdated; npm-check-updates -i",
|
|
39
|
+
"document": "license-report --only=prod,peer > LICENSES.json && license-report-check --source ./LICENSES.json --allowed 'MIT' --allowed 'n/a' --allowed 'Apache-2.0' --output=table",
|
|
37
40
|
"format": "prettier --write *.ts",
|
|
38
|
-
"lint": "
|
|
41
|
+
"lint": "eslint **/*.ts",
|
|
39
42
|
"publishToNPM": "npm publish --access public",
|
|
40
43
|
"release": "npm run syncWithGitHub && npm run build && npm run publishToNPM",
|
|
41
44
|
"syncWithGitHub": "npm run bumpVersion && node -e \"require('@datapos/datapos-development').syncWithGitHub()\"",
|
/package/{LICENSE.md → LICENSE}
RENAMED
|
File without changes
|