Skip to content
Calm motion: animations on this site only fade, with no movement

Weather forecast ​

The weather now and for the next days, with the high, the low, and the rain

Shows the weather of one place in a weather app, a travel site, or an event page. The data comes from your weather service.

Basic
Jakarta
31°C
Partly cloudy
Feels like
36°C
Humidity
74%
Wind
12 km/h
  • TueThunderstorm80% rainlow 25°C, high 32°C
  • WedRain65% rainlow 25°C, high 31°C
  • ThuPartly cloudy20% rainlow 26°C, high 33°C
  • FriClearlow 26°C, high 34°C
  • SatCloudy10% rainlow 25°C, high 32°C
  • place, temp, and weather give the weather now. feels-like, humidity in percent, and wind in km/h are optional.
  • weather is clear, partly-cloudy, cloudy, rain, storm, snow, or fog. Each has an icon and a word.
  • days is the list of days. Each day has a date as YYYY-MM-DD, a weather, a high, a low, and an optional rain chance in percent.
  • A bar shows the range of each day against the whole week, so warm and cool days are easy to see. Screen readers hear the weather word and "low 25°C, high 32°C".
  • unit is celsius (default) or fahrenheit. Give the numbers in that unit. locale formats the numbers and the names of the days.
  • Change the words with labels or a label pack. The API table lists the keys.

Usage ​

ts
import { BlessWeatherForecast } from "blessing-ui";

API ​

Props

NameTypeDefaultDescription
place*string—
temp*number—the temperature now, in the unit of `unit`
weather*BlessWeather—
feelsLikenumber—
humiditynumber—
windnumber—the wind speed in kilometers per hour
daysBlessWeatherDay[][]
unit"celsius" | "fahrenheit""celsius"
localestring"en"
labelsPartial<Record<BlessWeather, string> & { feelsLike: string; humidity: string; wind: string; days: string; rainOf: (pct: string) => string; range: (low: string, high: string) => string; }>—

Released under the MIT License. Character names and artwork belong to their owners.