-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintcache
1 lines (1 loc) · 4.33 KB
/
.eslintcache
1
[{"C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\index.js":"1","C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\App.js":"2","C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\reportWebVitals.js":"3","C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\components\\Weathercard.js":"4","C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\components\\Selectcity.js":"5","C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\api\\mainconfig.js":"6","C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\components\\Fetch.js":"7","C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\components\\List.js":"8"},{"size":547,"mtime":1611568358970,"results":"9","hashOfConfig":"10"},{"size":758,"mtime":1611579764363,"results":"11","hashOfConfig":"10"},{"size":362,"mtime":499162500000,"results":"12","hashOfConfig":"10"},{"size":2365,"mtime":1611574567203,"results":"13","hashOfConfig":"10"},{"size":1346,"mtime":1611574481679,"results":"14","hashOfConfig":"10"},{"size":121,"mtime":1611561186504,"results":"15","hashOfConfig":"10"},{"size":987,"mtime":1611571987047,"results":"16","hashOfConfig":"10"},{"size":726,"mtime":1611579763329,"results":"17","hashOfConfig":"10"},{"filePath":"18","messages":"19","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"20"},"o4cfmi",{"filePath":"21","messages":"22","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"23","messages":"24","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"20"},{"filePath":"25","messages":"26","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"20"},{"filePath":"27","messages":"28","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"20"},{"filePath":"29","messages":"30","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"20"},{"filePath":"31","messages":"32","errorCount":0,"warningCount":1,"fixableErrorCount":0,"fixableWarningCount":0,"source":"33","usedDeprecatedRules":"20"},{"filePath":"34","messages":"35","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\index.js",[],["36","37"],"C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\App.js",[],"C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\reportWebVitals.js",[],"C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\components\\Weathercard.js",[],"C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\components\\Selectcity.js",[],"C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\api\\mainconfig.js",[],"C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\components\\Fetch.js",["38"],"import React from 'react'\r\nimport {useState, useEffect} from 'react';\r\n\r\nconst Fetch = (initialUrl) => {\r\n const [data, setData] = useState(null);\r\n const [error, setError] = useState(null);\r\n const [isLoading, setIsLoading] = useState(null);\r\n const [url, setUrl] = useState(initialUrl);\r\n \r\n useEffect(() => {\r\n if(!url) return;\r\n setIsLoading(true);\r\n setData(null);\r\n setError(null);\r\n \r\n fetch(url)\r\n .then((response) => response.json())\r\n .then((data) => {\r\n setIsLoading(false);\r\n if(data.cod >= 400) {\r\n setError(data.message);\r\n return;\r\n }\r\n setData(data);\r\n })\r\n .catch((error) => {\r\n setIsLoading(false);\r\n setError(error);\r\n });\r\n }, [url]);\r\n \r\n return { data, error, isLoading, setUrl };\r\n \r\n}\r\n\r\nexport default Fetch\r\n","C:\\Users\\NITHISH\\Desktop\\weather-app\\weather-app\\src\\components\\List.js",[],{"ruleId":"39","replacedBy":"40"},{"ruleId":"41","replacedBy":"42"},{"ruleId":"43","severity":1,"message":"44","line":1,"column":8,"nodeType":"45","messageId":"46","endLine":1,"endColumn":13},"no-native-reassign",["47"],"no-negated-in-lhs",["48"],"no-unused-vars","'React' is defined but never used.","Identifier","unusedVar","no-global-assign","no-unsafe-negation"]