React-big-calendar: Work week example?

Created on 22 Feb 2018  路  4Comments  路  Source: jquense/react-big-calendar

Is there an example using the work_week view? I see that it was introduced in #383 but I do not see an example explicitly showing how it is used.

I am trying:

defaultView={'work_week'}

But it does not seem to work. Thanks.

Most helpful comment

Somehow it worked like this:

defaultView={'work_week'}
views={['day', 'work_week']}

All 4 comments

set the views prop to the ones you want. e.g views=['day', 'agenda', 'work_week', 'month']

Ah simple, not sure how I missed that. Thank you.

Hi.

views prop doesn't work for me.
I tried:
views={['work_week']}
Also the default:
views={['day', 'agenda', 'work_week', 'month']}

What I get is:
Uncaught TypeError: Cannot read property 'title' of undefined at Calendar.render
(modules.js?hash=e17e769497864e1c3da496c8e383db12da977918:1231)
which is kind of strange.

If I don't use the views prop, the calendar works as expected.

Somehow it worked like this:

defaultView={'work_week'}
views={['day', 'work_week']}
Was this page helpful?
0 / 5 - 0 ratings

Related issues

bionicvapourboy picture bionicvapourboy  路  3Comments

martinnov92 picture martinnov92  路  3Comments

crashspringfield picture crashspringfield  路  4Comments

jgautsch picture jgautsch  路  3Comments

connercms picture connercms  路  3Comments