Skip to content

samboylett/react-epg

Repository files navigation

React EPG

License: GPL v3 npm version Build Status codecov Mutation testing badge Codacy Badge

Installation

npm i --save react-epg

Usage

Documentation

Examples

import EPG, { Channel, TimeLine, TimeSlot, Show } from 'react-epg';

const MyEPG = () => (
  <EPG>
    <TimeLine channel={<Channel name="Sky" />}>
      <TimeSlot start={new Date('1/1/97 16:00')} end={new Date('1/1/97 16:30')}>
        <Show title="The Simpsons" />
      </TimeSlot>
      <TimeSlot start={new Date('1/1/97 16:30')} end={new Date('1/1/97 17:30')}>
        <Show title="Inception" />
      </TimeSlot>
    </TimeLine>
    <TimeLine channel={<Channel name="Dave" />}>
      <TimeSlot start={new Date('1/1/97 16:00')} end={new Date('1/1/97 17:00')}>
        <Show title="Top Gear" />
      </TimeSlot>
      <TimeSlot start={new Date('1/1/97 17:00')} end={new Date('1/1/97 18:45')}>
        <Show title="Shrek 3" />
      </TimeSlot>
    </TimeLine>
  </EPG>
);

About

TV guide style EPG component for React

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published