forked from chainapsis/keplr-wallet
-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
503c9bd
commit 81bf766
Showing
296 changed files
with
65,862 additions
and
9 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
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 |
---|---|---|
|
@@ -39,3 +39,5 @@ packages/proto-types/outputHash | |
|
||
package.json | ||
tsconfig.json | ||
|
||
wallet-api-example/* |
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
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 |
---|---|---|
@@ -0,0 +1,27 @@ | ||
.idea | ||
node_modules/ | ||
.DS_Store | ||
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. | ||
|
||
# dependencies | ||
/node_modules | ||
/.pnp | ||
.pnp.js | ||
|
||
# testing | ||
/coverage | ||
|
||
# production | ||
/build | ||
|
||
# misc | ||
.DS_Store | ||
.env.local | ||
.env.development.local | ||
.env.test.local | ||
.env.production.local | ||
|
||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
.yarn/* |
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 @@ | ||
nodeLinker: node-modules |
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,27 @@ | ||
# Keplr Example | ||
This is a simple example if how to use Keplr extension. | ||
|
||
## Requirements | ||
- Node.js v18+ | ||
- protoc v21.3 (recommended) | ||
```bash | ||
# This script is example for mac arm64 user. for other OS, replace URL(starts with https://..) to be matched with your OS from https://github.com/protocolbuffers/protobuf/releases/tag/v21.3 | ||
curl -Lo protoc-21.3.zip https://github.com/protocolbuffers/protobuf/releases/download/v21.3/protoc-21.3-osx-aarch_64.zip | ||
unzip protoc-21.3.zip -d $HOME/protoc | ||
cp -r $HOME/protoc/include /usr/local | ||
cp -r $HOME/protoc/bin /usr/local | ||
``` | ||
|
||
## Local Development | ||
|
||
Install dependencies | ||
|
||
```bash | ||
yarn install | ||
yarn proto-build | ||
``` | ||
|
||
Run development Server | ||
```bash | ||
yarn start | ||
``` |
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,22 @@ | ||
const webpack = require('webpack'); | ||
|
||
module.exports = function override(config) { | ||
const fallback = config.resolve.fallback || {}; | ||
Object.assign(fallback, { | ||
os: require.resolve("os-browserify/browser"), | ||
buffer: require.resolve("buffer/"), | ||
http: require.resolve("stream-http"), | ||
https: require.resolve("https-browserify"), | ||
crypto: require.resolve("crypto-browserify"), | ||
stream: require.resolve("stream-browserify"), | ||
process: require.resolve("process/browser"), | ||
}) | ||
config.resolve.fallback = fallback; | ||
config.plugins = (config.plugins || []).concat([ | ||
new webpack.ProvidePlugin({ | ||
process: 'process/browser', | ||
Buffer: ['buffer', 'Buffer'] | ||
}) | ||
]) | ||
return config; | ||
} |
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,56 @@ | ||
{ | ||
"name": "keplr-example", | ||
"version": "0.1.0", | ||
"private": true, | ||
"dependencies": { | ||
"@ethersproject/address": "^5.7.0", | ||
"@keplr-wallet/common": "^0.12.96", | ||
"@keplr-wallet/cosmos": "^0.12.96", | ||
"@keplr-wallet/provider-extension": "^0.12.96", | ||
"@keplr-wallet/types": "^0.12.96", | ||
"@keplr-wallet/unit": "^0.12.96", | ||
"@types/node": "^16.18.48", | ||
"@types/react": "^18.2.21", | ||
"@types/react-dom": "^18.2.7", | ||
"react": "^18.2.0", | ||
"react-dom": "^18.2.0", | ||
"react-scripts": "5.0.1", | ||
"typescript": "^4.9.5" | ||
}, | ||
"scripts": { | ||
"start": "react-app-rewired start", | ||
"build": "react-app-rewired build", | ||
"test": "react-app-rewired test", | ||
"eject": "react-scripts eject", | ||
"proto-build": "zx ./src/proto-types-gen/scripts/proto-gen.mjs" | ||
}, | ||
"eslintConfig": { | ||
"extends": [ | ||
"react-app" | ||
] | ||
}, | ||
"browserslist": { | ||
"production": [ | ||
">0.2%", | ||
"not dead", | ||
"not op_mini all" | ||
], | ||
"development": [ | ||
"last 1 chrome version", | ||
"last 1 firefox version", | ||
"last 1 safari version" | ||
] | ||
}, | ||
"devDependencies": { | ||
"buffer": "^6.0.3", | ||
"crypto-browserify": "^3.12.0", | ||
"https-browserify": "^1.0.0", | ||
"os-browserify": "^0.3.0", | ||
"process": "^0.11.10", | ||
"react-app-rewired": "^2.2.1", | ||
"stream-browserify": "^3.0.0", | ||
"stream-http": "^3.2.0", | ||
"ts-proto": "^1.157.0", | ||
"zx": "^7.2.3" | ||
} | ||
} |
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,16 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="utf-8" /> | ||
<meta name="viewport" content="width=device-width, initial-scale=1" /> | ||
<meta name="theme-color" content="#000000" /> | ||
<meta | ||
name="description" | ||
content="Web site created using create-react-app" | ||
/> | ||
<title>Keplr Example App</title> | ||
</head> | ||
<body> | ||
<div id="root"></div> | ||
</body> | ||
</html> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.