Files
pezkuwi-extension/packages/extension-inject
pezkuwichain ea2db6558f feat: complete Pezkuwi rebrand - remove other networks
- Remove all Polkadot ecosystem networks from chain selector
- Keep only: Pezkuwi Relay Chain, Zagros Relay Chain, Pezkuwi Beta Testnet
- Update extension ID from polkadot-js to pezkuwi
- Update PhishingDetected to use Pezkuwi branding
- Update metadataMock: Westend → Zagros, WND → ZGR
- Disable Ledger chains (no Pezkuwi Ledger app yet)
- Update Identicon to handle pezkuwi icon theme
- Clean up translation files

Breaking: Extension now only supports Pezkuwi networks
2026-01-08 23:46:33 +03:00
..

@polkadot/extension-inject

This is a basic extension injector that manages access to the global objects available. As an extension developer, you don't need to manage access to the window object manually, by just calling enable here, the global object is setup and managed properly. From here any dapp can access it with the @polkadot/extension-dapp package;

Usage

import { injectExtension } from '@polkadot/extension-inject';

// this a the function that will be exposed to be callable by the dapp. It resolves a promise
// with the injected interface, (see `Injected`) when the dapp at `originName` (url) is allowed
// to access functionality
function enableFn (originName: string): Promise<Injected> {
  ...
}

// injects the extension into the page
injectExtension(enableFn, { name: 'myExtension', version: '1.0.1' });