UNPKG

template_assets

Version:

![Compatibility](https://img.shields.io/badge/compatibility-0.6.25-blue) [![Build Status](https://github.com/dfinity/examples/workflows/motoko-superheroes-example/badge.svg)](https://github.com/dfinity/examples/actions?query=workflow%3Amotoko-superheroes

34 lines (31 loc) 943 B
import React from 'react'; import RootStack from "@navigation/RootStack"; import { defaultProviders } from "@connect2ic/core/providers" import { createClient } from "@connect2ic/core" import { Connect2ICProvider } from "@connect2ic/react" import { AstroX } from "@connect2ic/core/providers/astrox" import { PlugWallet } from "@connect2ic/core/providers/plug-wallet" import * as superheroes from '../declarations/superheroes.did.js'; import { canisterId } from '../declarations'; import { idlFactory } from '../declarations/superheroes.did.js'; import "@connect2ic/core/style.css" const client = createClient({ canisters: { superheroes: { canisterId, idlFactory } }, providers: [ new PlugWallet() ], host: window.location.origin, }) function App() { return ( <Connect2ICProvider client={client}> <RootStack /> </Connect2ICProvider> ); } export default App;