This file contains hidden or 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
| import { useEffect, useRef, useState } from 'react'; | |
| const isObjectEqual = (objA, objB) => { | |
| return JSON.stringify(objA) === JSON.stringify(objB); | |
| }; | |
| const useFetch = (url, options) => { | |
| const [result, setResult] = useState(null); | |
| const [loading, setLoading] = useState(false); | |
| const [shouldLoad, setShouldLoad] = useState(false); |
This file contains hidden or 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
| { | |
| "ofertas": [ | |
| { | |
| "id": 1, | |
| "categoria": "restaurante", | |
| "titulo": "Super Burger", | |
| "descricao_oferta": "Rodízio de Mini-hambúrger com opção de entrada.", | |
| "anunciante": "Original Burger", | |
| "valor": 15.90, | |
| "destaque": true, |
NewerOlder