Sadly, Weather Underground haven’t yet (after 6 years!) updated their API docs. For differentiating between daytime and nighttime icons, one can use the newer v11 conditions API, i.e.:
which will give icon properties with a prepended nt_ if it is nighttime, much like their own URIs returned in icon_url.
For these, we’d need an appropriate class mapping within weather-icons.css.
I patched up my own copy of weather-icons.css like below, but it should be done correctly, so it’d work with SASS and other stuff. Also, the documentation needs an update.
Here’s how I changed the "Wunderground" part of weather-icons.css:
Sadly, Weather Underground haven’t yet (after 6 years!) updated their API docs. For differentiating between daytime and nighttime icons, one can use the newer v11 conditions API, i.e.:
instead of the older
which will give
icon
properties with a prependednt_
if it is nighttime, much like their own URIs returned inicon_url
.For these, we’d need an appropriate class mapping within
weather-icons.css
.I patched up my own copy of
weather-icons.css
like below, but it should be done correctly, so it’d work with SASS and other stuff. Also, the documentation needs an update.Here’s how I changed the "Wunderground" part of
weather-icons.css
: