import { ResaleItemWithMetadata } from './types' ; type ResaleItemGroups = { [ address ] : ResaleItemWithMetadata [ ] ; } ; export default class Utils { groupResaleItems ( resaleItems ) { const output = { } ; resaleItems . forEach ( resaleItem => { output [ resaleItem . tokenAddress ] = output [ resaleItem . tokenAddress ] || [ ] ; output [ resaleItem . tokenAddress ] . push ( resaleItem ) ; } ) ; return output ; } }