weather icons again
This commit is contained in:
@@ -38,9 +38,11 @@ app.use(helmet({
|
|||||||
imgSrc: [
|
imgSrc: [
|
||||||
"'self'",
|
"'self'",
|
||||||
"data:",
|
"data:",
|
||||||
|
"https:",
|
||||||
"https://maps.googleapis.com",
|
"https://maps.googleapis.com",
|
||||||
"https://maps.gstatic.com",
|
"https://maps.gstatic.com",
|
||||||
"https://openweathermap.org"
|
"https://openweathermap.org",
|
||||||
|
"https://*.openweathermap.org"
|
||||||
],
|
],
|
||||||
connectSrc: ["'self'", "https://api.openweathermap.org"]
|
connectSrc: ["'self'", "https://api.openweathermap.org"]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -93,7 +93,7 @@ const Weather = () => {
|
|||||||
<div className="font-medium">
|
<div className="font-medium">
|
||||||
{new Date(d.date).toLocaleDateString(undefined, { weekday: 'short' })}
|
{new Date(d.date).toLocaleDateString(undefined, { weekday: 'short' })}
|
||||||
</div>
|
</div>
|
||||||
<img alt="" className="mx-auto" width="40" height="40" src={`https://openweathermap.org/img/wn/${d.icon}.png`} />
|
<img alt="" className="mx-auto" width="40" height="40" src={`https://openweathermap.org/img/wn/${d.icon}@2x.png`} />
|
||||||
<div>{d.temperatureHigh}° / {d.temperatureLow}°</div>
|
<div>{d.temperatureHigh}° / {d.temperatureLow}°</div>
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
|
|||||||
Reference in New Issue
Block a user