@lifi/composer-sdk
Version:
Public Composer SDK for building and submitting flows
1 lines • 815 B
Source Map (JSON)
{"version":3,"sources":["../src/outputs.ts"],"sourcesContent":["import type { Outputs, TerminalOutput } from '@lifi/compose-spec';\n\n/**\n * The entries of `outputs` the caller actually receives: every port no later\n * node spends, keyed `<nodeId>.<portName>` as on the wire. Consumed ports\n * (intermediate amounts a later op takes as input) are dropped.\n */\nexport const terminalOutputs = (\n outputs: Outputs,\n): Record<string, TerminalOutput> =>\n Object.fromEntries(\n Object.entries(outputs).filter(\n (entry): entry is [string, TerminalOutput] =>\n entry[1].role === 'terminal',\n ),\n );\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAOO,MAAM,kBAAkB,CAC7B,YAEA,OAAO;AAAA,EACL,OAAO,QAAQ,OAAO,EAAE;AAAA,IACtB,CAAC,UACC,MAAM,CAAC,EAAE,SAAS;AAAA,EACtB;AACF;","names":[]}