Skip to content

Commit 4f70208

Browse files
authored
Add Asset hub options to polkadot-types-internal-metadata (#6062)
1 parent 75f594b commit 4f70208

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

packages/typegen/src/metadataMd.ts

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,12 @@ import { Metadata, TypeRegistry, Vec } from '@polkadot/types';
1717
import * as definitions from '@polkadot/types/interfaces/definitions';
1818
import { getStorage as getSubstrateStorage } from '@polkadot/types/metadata/decorate/storage/getStorage';
1919
import { unwrapStorageType } from '@polkadot/types/util';
20+
import assetHubKusamaMeta from '@polkadot/types-support/metadata/v15/asset-hub-kusama-hex';
21+
import assetHubKusamaRpc from '@polkadot/types-support/metadata/v15/asset-hub-kusama-rpc';
22+
import assetHubKusamaVer from '@polkadot/types-support/metadata/v15/asset-hub-kusama-ver';
23+
import assetHubPolkadotMeta from '@polkadot/types-support/metadata/v15/asset-hub-polkadot-hex';
24+
import assetHubPolkadotRpc from '@polkadot/types-support/metadata/v15/asset-hub-polkadot-rpc';
25+
import assetHubPolkadotVer from '@polkadot/types-support/metadata/v15/asset-hub-polkadot-ver';
2026
import kusamaMeta from '@polkadot/types-support/metadata/v15/kusama-hex';
2127
import kusamaRpc from '@polkadot/types-support/metadata/v15/kusama-rpc';
2228
import kusamaVer from '@polkadot/types-support/metadata/v15/kusama-ver';
@@ -58,6 +64,16 @@ interface StaticDef {
5864
const headerFn = (runtimeDesc: string) => `\n\n(NOTE: These were generated from a static/snapshot view of a recent ${runtimeDesc}. Some items may not be available in older nodes, or in any customized implementations.)`;
5965

6066
const ALL_STATIC: Record<string, StaticDef> = {
67+
'asset-hub-kusama': {
68+
meta: assetHubKusamaMeta,
69+
rpc: assetHubKusamaRpc,
70+
ver: assetHubKusamaVer as unknown as { apis: ApiDef[] }
71+
},
72+
'asset-hub-polkadot': {
73+
meta: assetHubPolkadotMeta,
74+
rpc: assetHubPolkadotRpc,
75+
ver: assetHubPolkadotVer as unknown as { apis: ApiDef[] }
76+
},
6177
kusama: {
6278
meta: kusamaMeta,
6379
rpc: kusamaRpc,

0 commit comments

Comments
 (0)