-
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.
Merge pull request #19 from desci-labs/m0ar/remove-poc-app
Remove PoC webapp, general cleanup
- Loading branch information
Showing
69 changed files
with
2,922 additions
and
5,191 deletions.
There are no files selected for viewing
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 @@ | ||
src/__generated__/* |
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,18 @@ | ||
module.exports = { | ||
extends: [ | ||
'eslint:recommended', | ||
'plugin:@typescript-eslint/recommended', | ||
'plugin:prettier/recommended' | ||
], | ||
parser: '@typescript-eslint/parser', | ||
plugins: [ | ||
'@typescript-eslint', | ||
'prettier', | ||
], | ||
root: true, | ||
rules: { | ||
"prettier/prettier": "error", | ||
"no-unused-vars": "off", | ||
"@typescript-eslint/no-unused-vars": ["error", { "varsIgnorePattern": "^_" }] | ||
} | ||
}; |
This file was deleted.
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 |
---|---|---|
@@ -1,6 +1,6 @@ | ||
on: | ||
pull_request: | ||
branches: | ||
branches: | ||
- main | ||
jobs: | ||
test: | ||
|
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,8 @@ | ||
#!/usr/bin/env sh | ||
. "$(dirname -- "$0")/_/husky.sh" | ||
|
||
if ! npm run lint:check; then | ||
echo "⚠️ Linting failed, trying to fix. Solve any remaining issues and try again." | ||
npm run lint:fix | ||
exit 1 | ||
fi |
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 |
---|---|---|
@@ -1,39 +1,39 @@ | ||
{ | ||
"editor.codeActionsOnSave": { | ||
"source.fixAll.eslint": true | ||
}, | ||
"files.exclude": { | ||
"**/.git": true, | ||
"**/.svn": true, | ||
"**/.hg": true, | ||
"**/CVS": true, | ||
"**/.DS_Store": true, | ||
"**/Thumbs.db": true | ||
}, | ||
"hide-files.files": [], | ||
"editor.formatOnSave": true, // Tell VSCode to format files on save | ||
"editor.defaultFormatter": "esbenp.prettier-vscode", | ||
"typescript.format.enable": false, | ||
"[typescript]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode", | ||
"editor.formatOnSave": true, | ||
"editor.codeActionsOnSave": { | ||
"source.fixAll.eslint": true | ||
}, | ||
"files.exclude": { | ||
"**/.git": true, | ||
"**/.svn": true, | ||
"**/.hg": true, | ||
"**/CVS": true, | ||
"**/.DS_Store": true, | ||
"**/Thumbs.db": true | ||
}, | ||
"hide-files.files": [], | ||
"editor.formatOnSave": true, // Tell VSCode to format files on save | ||
/// TSX auto format on save ESLint | ||
"source.fixAll.eslint": true | ||
} | ||
}, | ||
"[typescriptreact]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode", | ||
"typescript.format.enable": false, | ||
"[typescript]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode", | ||
"editor.formatOnSave": true, | ||
"editor.codeActionsOnSave": { | ||
/// TSX auto format on save ESLint | ||
"source.fixAll.eslint": true | ||
} | ||
}, | ||
"[typescriptreact]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode", | ||
"editor.formatOnSave": true, | ||
"editor.codeActionsOnSave": { | ||
/// TSX auto format on save ESLint | ||
"source.fixAll.eslint": true | ||
} | ||
}, | ||
"[xml]": { | ||
"editor.defaultFormatter": "redhat.vscode-xml" | ||
}, | ||
"[properties]": { | ||
"editor.defaultFormatter": "foxundermoon.shell-format" | ||
"editor.formatOnSave": true, | ||
"editor.codeActionsOnSave": { | ||
/// TSX auto format on save ESLint | ||
"source.fixAll.eslint": true | ||
} | ||
}, | ||
"[xml]": { | ||
"editor.defaultFormatter": "redhat.vscode-xml" | ||
}, | ||
"[properties]": { | ||
"editor.defaultFormatter": "foxundermoon.shell-format" | ||
} | ||
} |
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
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 |
---|---|---|
@@ -1,37 +1,47 @@ | ||
# ComposeDB configuration | ||
This is a rough take on model definitions for DeSci Nodes on Ceramic and ComposeDB, | ||
based on a Ceramic demo at ETHDenver and snippets from Mark Krasner. | ||
# Protocol V2 reference implementation | ||
This repo contains a reference implementation for the next generation of the protocol, built on [Ceramic](https://ceramic.network/) and [ComposeDB](https://composedb.js.org/docs/0.5.x/introduction). It includes data models and an extensive test suite to ensure correct functionality, but also example data population and a GraphiQL interface to explore the protocol structure. | ||
|
||
## Getting Started | ||
1. Install your dependencies: | ||
By default, the application runs a local Ceramic/ComposeDB node with the bundled IPFS server, uses the `inmemory` network for anchoring, and writes all data and logs to `local-data`. | ||
|
||
The protocol documentation can be found [here](pls-replace-me)! | ||
|
||
## Getting started | ||
|
||
1. Install dependencies: | ||
|
||
```bash | ||
nvm use # ensure node 20 is selected according to .nvmrc | ||
npm install | ||
nvm use # or otherwise ensure the use of node v20 | ||
npm ci # install deps | ||
``` | ||
|
||
2. Generate your admin seed, admin did, and ComposeDB configuration file: | ||
2. Generate your own seed, admin DID, and ComposeDB configuration file: | ||
|
||
```bash | ||
npm run generate | ||
``` | ||
|
||
3. Finally, run your application in a new terminal: | ||
3. Finally, start the services: | ||
|
||
```bash | ||
npm run dev | ||
``` | ||
- Open [http://localhost:3000](http://localhost:3000) to get to Nodes Home | ||
- Open [http://localhost:5001](http://localhost:5001) for the GraphiQL interface | ||
|
||
## Reset | ||
To clean everything up, delete `local-data`. This is necessary when changing networks, for example. | ||
Now you can open [http://localhost:5001](http://localhost:5001) for the GraphiQL interface and explore the data models. | ||
|
||
## Tests | ||
There is a test suite running through API operations demonstrating the functional protocol | ||
requirements in an isolated ceramic instance not to dirty down the state, but can also be | ||
run against the dev process. Not both at the same time though, because the ports overlap. | ||
## Test suite | ||
|
||
There is a test suite running through API operations demonstrating the functional protocol requirements, by generating random DID's and performing create and mutation operations. Before each run, it will remove the remains of the last test execution. | ||
|
||
The test setup clones your user configuration, but changes storage to `local-data/ceramic-test` not to interfere with prepopulated data. It will refuse to run if `npm run dev` is already active. | ||
|
||
```bash | ||
make test | ||
``` | ||
``` | ||
|
||
## Reset | ||
|
||
To reset to a clean state, deleting everything except generated seed and user config: | ||
|
||
```bash | ||
make clean | ||
``` |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.