Files
common/packages/code-primitives-json/src/accountId/encode.ts
T
Jaco Greeff 78e01a0e16 Combine util, types & trie into common (#150)
* Pull in trie repo

* Bring in types repo
2018-06-26 21:26:51 +02:00

13 lines
446 B
TypeScript

// Copyright 2017-2018 @polkadot/primitives-json authors & contributors
// This software may be modified and distributed under the terms
// of the ISC license. See the LICENSE file for details.
import { AccountId } from '@polkadot/primitives/base';
import { JsonAccountId } from '../types';
import hashEncode from '../hash/encode';
export default function accountIdEncode (value: AccountId): JsonAccountId {
return hashEncode(value, 160);
}