Skip to main content

pluginRegistry

Global plugin registry instance for managing FCL plugins. This registry handles the registration and management of various FCL plugins including service plugins that add new wallet services and strategies.

Import

You can import the entire package and access the function:


_10
import * as fcl from "@onflow/fcl-react-native"
_10
_10
fcl.pluginRegistry()

Or import directly the specific function:


_10
import { pluginRegistry } from "@onflow/fcl-react-native"
_10
_10
pluginRegistry()

Usage


_10
// Add a plugin to the registry
_10
pluginRegistry.add({
_10
name: "MyWalletPlugin",
_10
f_type: "ServicePlugin",
_10
type: "discovery-service",
_10
services: [...],
_10
serviceStrategy: { method: "CUSTOM/RPC", exec: customExecFunction }
_10
})

Returns


_10
Readonly<{ add: (plugins: any) => void; getPlugins: () => Map<any, any>; }>


Rate this page