UNPKG

synapse-react-client

Version:

[![npm version](https://badge.fury.io/js/synapse-react-client.svg)](https://badge.fury.io/js/synapse-react-client) [![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square)](https://github.com/prettier/prettie

28 lines (27 loc) 744 B
import { useSynapseContext as e } from "../../utils/context/SynapseContext.js"; import { waitForAsyncResult as r } from "@sage-bionetworks/synapse-client"; import { useMutation as i } from "@tanstack/react-query"; function y(s) { const { synapseClient: o } = e(); return i({ ...s, mutationFn: async (n) => { const t = await o.gridServicesClient.postRepoV1GridDownloadCsvAsyncStart( { downloadFromGridRequest: n } ); return (await r( () => o.asynchronousJobServicesClient.getRepoV1AsynchronousJobJobId( { jobId: t.token } ) )).responseBody; } }); } export { y as useExportGridAsCsv }; //# sourceMappingURL=useExportGrid.js.map