Liferay.Loader.define("data-engine-taglib@3.3.50/data_layout_builder/js/hooks/useRequest.es",["module","exports","require","liferay!frontend-js-react-web$react","../utils/client.es"],(function(e,r,t){window;Object.defineProperty(r,"__esModule",{value:!0}),r.default=function useRequest(e){const[r,t]=(0,s.useState)({error:null,isLoading:!0,response:{}});return(0,s.useEffect)((()=>{(0,n.request)(e).then((e=>e.json())).then((e=>{t({error:null,isLoading:!1,response:e})})).catch((e=>{t({error:e,isLoading:!1,response:{}})}))}),[e]),r};var s=t("liferay!frontend-js-react-web$react"),n=t("../utils/client.es")}));
//# sourceMappingURL=useRequest.es.js.map