Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
R

react-big-calendar

> 编程语言
Open source

gcal/outlook like calendar component

8.7K stars0 likes3 views
WebsiteGitHub

About

gcal/outlook like calendar component

react-big-calendar

An events calendar component built for React and designed for modern browsers (read: not IE) and uses flexbox over the classic tables-caption approach.

DEMO and Docs

Inspired by Full Calendar.

Use and Setup

yarn add react-big-calendar or npm install --save react-big-calendar

Include react-big-calendar/lib/css/react-big-calendar.css for styles, and make sure your calendar's container element has a height, or the calendar won't be visible. To provide your own custom styling, see the Custom Styling topic.

Starters

  • react-big-calendar
  • react-big-calendar with drag and drop
  • react-big-calendar with TypeScript and React hooks bundled with Vite

Run examples locally

bash
$ git clone [email protected]:bigcalendar/react-big-calendar.git
$ cd react-big-calendar
$ yarn
$ yarn storybook
  • Open localhost:9002.

Localization and Date Formatting

react-big-calendar includes four options for handling the date formatting and culture localization, depending on your preference of DateTime libraries. You can use either the Moment.js, Globalize.js, date-fns, Day.js localizers.

Regardless of your choice, you must choose a localizer to use this library:

Moment.js

javascript
import { Calendar, momentLocalizer } from 'react-big-calendar'
import moment from 'moment'

const localizer = momentLocalizer(moment)

const MyCalendar = (props) => (
  

)

Globalize.js v0.1.1

javascript
import { Calendar, globalizeLocalizer } from 'react-big-calendar'
import globalize from 'globalize'

const localizer = globalizeLocalizer(globalize)

const MyCalendar = (props) => (
  

)

date-fns v2

javascript
import { Calendar, dateFnsLocalizer } from 'react-big-calendar'
import format from 'date-fns/format'
import parse from 'date-fns/parse'
import startOfWeek from 'date-fns/startOfWeek'
import getDay from 'date-fns/getDay'
import enUS from 'date-fns/locale/en-US'

const locales = {
  'en-US': enUS,
}

const localizer = dateFnsLocalizer({
  format,
  parse,
  startOfWeek,
  getDay,
  locales,
})

const MyCalendar = (props) => (
  

)

Day.js

Note that the dayjsLocalizer extends Day.js with the following plugins:

  • IsBetween
  • IsLeapYear
  • IsSameOrAfter
  • IsSameOrBefore
  • LocaleData
  • LocalizedFormat
  • MinMax
  • UTC
javascript
import { Calendar, dayjsLocalizer } from 'react-big-calendar'
import dayjs from 'dayjs'

const localizer = dayjsLocalizer(dayjs)

const MyCalendar = (props) => (
  

)

Custom Styling

Out of the box, you can include the compiled CSS files and be up and running. But, sometimes, you may want to style Big Calendar to match your application styling. For this reason, SASS files are included with Big Calendar.

  @import 'react-big-calendar/lib/sass/styles';
  @import 'react-big-calendar/lib/addons/dragAndDrop/styles'; // if using DnD

SASS implementation provides a variables file containing color and sizing variables that you can update to fit your application. Note: Changing and/or overriding styles can cause rendering issues with your Big Calendar. Carefully test each change accordingly.

Join The Community

Help us improve Big Calendar! Join us on Slack. (Slack invite links do expire. If you can't get in, just file an issue and we'll get a new link.)

Translations

  • العربية

Issues· 119 open

View all issuesOpen on GitHub
  • #2817

    Slot selection stops responding to the mouse after a touch (and the other way around)

    bugUpdated Sep 28, 2026
  • #2764

    Dropdown controls are not accessible with keyboard using tab or arrow keys in windows.

    bugUpdated Sep 23, 2026
  • #2538

    [Accessibility] "Ensure elements with ARIA role that require child roles contain them

    bugUpdated Sep 10, 2026
  • #2814

    resourceGroupingLayout: a multi-day all-day event is missing from the days between its start and end

    Updated Sep 9, 2026
  • #2809

    Drag/drop stops working when the calendar is rendered into another document (portal to a separate window or iframe)

    bugUpdated Jun 29, 2026
  • #2807

    dayJS timezone plugin makes "week" and "day" views start-of-day timezone dependent

    bugUpdated Jun 23, 2026
  • #2806

    Customize Component Rendering throws 'specialDay' error in storybook

    bugUpdated Jun 16, 2026
  • #2434

    Actions buttons don't do anytning, silently fail.

    bugUpdated Jun 15, 2026
  • #1530

    Overlap's algorithm fails with custom timeslots and steps

    Updated May 19, 2026
  • #1598

    Cannot correctly resize or move multi-day events with showMultiDayTimes

    Updated May 19, 2026

> Tags

JavaScript

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 29, 2026
Category编程语言
PricingOpen source

> Related tools

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言