File tree Expand file tree Collapse file tree 2 files changed +10
-10
lines changed Expand file tree Collapse file tree 2 files changed +10
-10
lines changed Original file line number Diff line number Diff line change @@ -8,13 +8,7 @@ import { Porto } from "porto";
88
99import type { EIP6963ProviderInfo , EIP1193 , AnnounceEvent } from "./types.ts" ;
1010
11- const ALL_CHAINS : Chain [ ] = Object . values ( chains ) . filter (
12- ( c : any ) =>
13- typeof c === "object" &&
14- c !== null &&
15- "id" in c &&
16- typeof ( c as any ) . id === "number"
17- ) ;
11+ const ALL_CHAINS : Chain [ ] = Object . values ( chains ) as Chain [ ] ;
1812const byId = ( id : number ) => ALL_CHAINS . find ( ( c ) => c . id === id ) ;
1913
2014export function App ( ) {
Original file line number Diff line number Diff line change @@ -6,9 +6,15 @@ export type EIP6963ProviderInfo = {
66} ;
77
88export type EIP1193 = {
9- request : ( args : { method : string ; params ?: any [ ] | object } ) => Promise < any > ;
10- on ?: ( event : string , listener : ( ...args : any [ ] ) => void ) => void ;
11- removeListener ?: ( event : string , listener : ( ...args : any [ ] ) => void ) => void ;
9+ request : ( args : {
10+ method : string ;
11+ params ?: unknown [ ] | object ;
12+ } ) => Promise < unknown > ;
13+ on ?: ( event : string , listener : ( ...args : unknown [ ] ) => void ) => void ;
14+ removeListener ?: (
15+ event : string ,
16+ listener : ( ...args : unknown [ ] ) => void
17+ ) => void ;
1218} ;
1319
1420export type AnnounceEvent = CustomEvent < {
You can’t perform that action at this time.
0 commit comments