Skip to content

Commit

Permalink
feat(cbcd-bridging-app): add frontend folder
Browse files Browse the repository at this point in the history
Signed-off-by: André Augusto <andre.augusto@tecnico.ulisboa.pt>
  • Loading branch information
AndreAugusto11 committed Nov 4, 2022
1 parent a6d0322 commit ecbc579
Show file tree
Hide file tree
Showing 4 changed files with 99 additions and 11 deletions.
22 changes: 11 additions & 11 deletions examples/cactus-example-cbdc-bridging-backend/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@hyperledger/cactus-example-cbdc-bridging-backend",
"version": "1.0.0",
"version": "1.1.1",
"description": "An example application showing how to use Cactus when implementing a CBDC bridging application between Hyperledger Fabric and Hyperledger Besu.",
"keywords": [
"Hyperledger",
Expand Down Expand Up @@ -55,16 +55,16 @@
"build:dev:backend:postbuild": "mkdir ./dist/lib/fabric-contracts && cp -r ./src/fabric-contracts/* ./dist/lib/fabric-contracts/"
},
"dependencies": {
"@hyperledger/cactus-api-client": "1.1.0",
"@hyperledger/cactus-cmd-api-server": "1.1.0",
"@hyperledger/cactus-common": "1.1.0",
"@hyperledger/cactus-core": "1.1.0",
"@hyperledger/cactus-core-api": "1.1.0",
"@hyperledger/cactus-plugin-keychain-memory": "1.1.0",
"@hyperledger/cactus-plugin-ledger-connector-fabric": "1.1.0",
"@hyperledger/cactus-plugin-ledger-connector-xdai": "1.1.0",
"@hyperledger/cactus-plugin-odap-hermes": "1.1.0",
"@hyperledger/cactus-test-tooling": "1.1.0",
"@hyperledger/cactus-api-client": "1.1.1",
"@hyperledger/cactus-cmd-api-server": "1.1.1",
"@hyperledger/cactus-common": "1.1.1",
"@hyperledger/cactus-core": "1.1.1",
"@hyperledger/cactus-core-api": "1.1.1",
"@hyperledger/cactus-plugin-keychain-memory": "1.1.1",
"@hyperledger/cactus-plugin-ledger-connector-fabric": "1.1.1",
"@hyperledger/cactus-plugin-ledger-connector-xdai": "1.1.1",
"@hyperledger/cactus-plugin-odap-hermes": "1.1.1",
"@hyperledger/cactus-test-tooling": "1.1.1",
"@openzeppelin/contracts": "4.4.2",
"@openzeppelin/contracts-upgradeable": "4.4.2",
"async-exit-hook": "2.0.1",
Expand Down
46 changes: 46 additions & 0 deletions examples/my-app/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
{
"name": "my-app",
"version": "1.1.1",
"private": true,
"dependencies": {
"@testing-library/jest-dom": "5.16.5",
"@testing-library/react": "13.4.0",
"@testing-library/user-event": "13.5.0",
"@types/jest": "27.5.2",
"@types/node": "16.18.3",
"@types/react": "18.0.24",
"@types/react-dom": "18.0.8",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-scripts": "5.0.1",
"typescript": "4.8.4",
"web-vitals": "2.1.4",
"@material-ui/core": "4.12.4",
"@material-ui/icons": "4.11.3",
"@material-ui/lab": "4.0.0-alpha.61",
"@mui/material": "5.10.2",
"axios": "0.27.2",
"eslint-config-react-app": "7.0.1"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {

},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
}
}
12 changes: 12 additions & 0 deletions jest.config.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

30 changes: 30 additions & 0 deletions jest.resolver.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

module.exports = (path, options) => {
// Call the defaultResolver, so we leverage its cache, error handling, etc.
return options.defaultResolver(path, {
...options,
// Use packageFilter to process parsed `package.json` before the resolution (see https://www.npmjs.com/package/resolve#resolveid-opts-cb)
packageFilter: pkg => {
// This is a workaround for https://github.com/uuidjs/uuid/pull/616
//
// jest-environment-jsdom 28+ tries to use browser exports instead of default exports,
// but uuid only offers an ESM browser export and not a CommonJS one. Jest does not yet
// support ESM modules natively, so this causes a Jest error related to trying to parse
// "export" syntax.
//
// This workaround prevents Jest from considering uuid's module-based exports at all;
// it falls back to uuid's CommonJS+node "main" property.
//
// Once we're able to migrate our Jest config to ESM and a browser crypto
// implementation is available for the browser+ESM version of uuid to use (eg, via
// https://github.com/jsdom/jsdom/pull/3352 or a similar polyfill), this can go away.
if (pkg.name === 'uuid') {
delete pkg['exports'];
delete pkg['module'];
}
return pkg;
},
});
};

0 comments on commit ecbc579

Please sign in to comment.