import { ICommandTypes } from './commands' ; export default function getMarkdownCommandWithArgs < K extends keyof ICommandTypes > ( key , args , serialize = ( args ) => [ JSON . stringify ( args ) ] ) { return `command:${ key }?${ encodeURIComponent ( JSON . stringify ( serialize ( args ) ) ) }` ; }