-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Implement contact exchange library with OOB invitation process…
…ing and wallet management
- Loading branch information
1 parent
354e337
commit 4653ce9
Showing
22 changed files
with
743 additions
and
23 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{ | ||
"extends": ["../../.eslintrc.json"], | ||
"ignorePatterns": ["!**/*"], | ||
"overrides": [ | ||
{ | ||
"files": ["*.ts", "*.tsx", "*.js", "*.jsx"], | ||
"rules": {} | ||
}, | ||
{ | ||
"files": ["*.ts", "*.tsx"], | ||
"rules": {} | ||
}, | ||
{ | ||
"files": ["*.js", "*.jsx"], | ||
"rules": {} | ||
}, | ||
{ | ||
"files": ["*.json"], | ||
"parser": "jsonc-eslint-parser", | ||
"rules": { | ||
"@nx/dependency-checks": "error" | ||
} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# Contact Exchange Library | ||
|
||
This library was generated with [Nx](https://nx.dev). | ||
|
||
# Building the Library | ||
|
||
- Before builld, please move to the root directory of the library folder, that is **contact-exchange** and installl dependencies with : | ||
|
||
```bash | ||
npm i | ||
`` | ||
|
||
## Building | ||
|
||
Run `npm run build ` to build the library. | ||
|
||
## Running unit tests | ||
|
||
Run `nx run test ` to execute the unit tests via [Jest](https://jestjs.io). | ||
|
||
## Basic overview of the library | ||
|
||
``` | ||
|
||
+---------------+ | ||
| Wallet | | ||
+---------------+ | ||
| | ||
| DIDComm Messaging | ||
| | ||
v | ||
+---------------+ | ||
| Contact Storage| | ||
+---------------+ | ||
| | ||
| (Accessible by all identities) | ||
| | ||
v | ||
+---------------+ | ||
| Identities | | ||
+---------------+ | ||
| | ||
| DIDComm Messaging | ||
| | ||
v | ||
+---------------+ | ||
| Wallet | | ||
+---------------+ | ||
|
||
``` | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
// jest.config.js | ||
module.exports = { | ||
preset: 'ts-jest', | ||
testEnvironment: 'jsdom', | ||
transform: { | ||
'^.+\\.ts$': [ | ||
'ts-jest', | ||
{ | ||
tsconfig: '<rootDir>/tsconfig.spec.json', | ||
}, | ||
], | ||
}, | ||
testMatch: ['**/tests/**/*.test.ts', '**/src/**/*.test.ts'], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
{ | ||
"name": "@datev/contact-exchange", | ||
"version": "0.0.1", | ||
"dependencies": { | ||
"jest-worker": "^29.7.0", | ||
"tslib": "^2.3.0" | ||
}, | ||
"type": "commonjs", | ||
"main": "./dist/index.js", | ||
"typings": "./dist/index.d.ts", | ||
"devDependencies": { | ||
"@types/jest": "^29.5.13", | ||
"jest": "^29.7.0", | ||
"ts-jest": "^29.2.5", | ||
"typescript": "^5.0.0" | ||
}, | ||
"scripts": { | ||
"build": "tsc", | ||
"test": "jest" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
{ | ||
"name": "contact-exchange", | ||
"$schema": "../../node_modules/nx/schemas/project-schema.json", | ||
"sourceRoot": "libs/contact-exchange/src", | ||
"projectType": "library", | ||
"targets": { | ||
"build": { | ||
"executor": "@nx/js:tsc", | ||
"outputs": ["{options.outputPath}"], | ||
"options": { | ||
"outputPath": "dist/libs/contact-exchange", | ||
"main": "libs/contact-exchange/src/index.ts", | ||
"tsConfig": "libs/contact-exchange/tsconfig.lib.json", | ||
"assets": ["libs/contact-exchange/*.md"] | ||
} | ||
}, | ||
"lint": { | ||
"executor": "@nx/eslint:lint", | ||
"outputs": ["{options.outputFile}"] | ||
}, | ||
"test": { | ||
"executor": "@nx/jest:jest", | ||
"outputs": ["{workspaceRoot}/coverage/{projectRoot}"], | ||
"options": { | ||
"jestConfig": "libs/contact-exchange/jest.config.ts" | ||
} | ||
} | ||
}, | ||
"tags": [] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export * from './lib/contact-exchange'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import { contactExchange } from './contact-exchange'; | ||
|
||
describe('contactExchange', () => { | ||
it('should work', () => { | ||
expect(contactExchange()).toEqual('contact-exchange'); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
export function contactExchange(): string { | ||
return 'contact-exchange'; | ||
} |
Oops, something went wrong.