Last active
July 11, 2020 15:57
-
-
Save yuripramos/a50fc467b253f8779ae7f06bee6cbd9d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export const fetchSmallDevicesData = async ( | |
resolution, | |
filters, | |
pages | |
) => { | |
const { data } = await axios.get( | |
`${URL}?${buildSmartDevicesParameters( | |
resolutions, | |
filters, | |
pages | |
)}` | |
); | |
return { | |
smallDevices: data | |
}; | |
}; | |
const { loading, data } = useFetch( | |
() => fetchSmallDevicesData(resolution, filters, pages), | |
[resolution, filters, pages] | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment