A react library with components and hooks for interacting with Orby.
Orby is an RPC-proxy that wraps around standard RPCs and extends their functionality to enable gas abstraction, gas sponsorship, and chain abstraction for any account (including EOAs) with just a few lines of code. Additionally, it allows wallets to monetize on any transaction from their users.
// add imports
import {
OrbyKitProvider,
useTransaction,
useOrbyKit,
OrbyKitConfig,
} from "@orb-labs/orbykit";
// set the configs
const orbyKitConfig: OrbyKitConfig = {
instancePrivateAPIKey: "instance private api key",
instancePublicAPIKey: "instance public api key",
appName: "Example",
environment: BlockchainEnvironment.TESTNET
};
<OrbyKitProvider config={orbyKitConfig}>
// your components here
</OrbyKitProvider>
Run yarn run dev
- Bump the package.json version
// package.json
version: "0.0.8-alpha" // change to "0.0.9-alpha"
- Run yarn at the root of orby folder
yarn
- Build
yarn workspace @orb-labs/orbykit build
- Login to npm
yarn npm login
- Publish @orb-labs/orbykit to npm
yarn workspace @orb-labs/orbykit npm publish --access public