1.0.1 • Published 3 years ago

portal-web-timeline v1.0.1

Weekly downloads
-
License
Proprietary
Repository
github
Last release
3 years ago

Portal Web Timeline:

Based on jsainsburyplc/react-timelines version 2.7.2.

Publish to NPM repo:

git commit -am "description"

npm version patch                         # to increment patch number, or minor/major to increment minor/major number.

npm publish

For local debugging:

cd path_to_timeline_proj

npm link                                  # create a link to the global repo dir.

cd path_to_proj

rm -rf ./node_modules/portal-web-timeline

npm link portal-web-timeline              # symlink to global repo dir.

Check link

dir ./node_modules

should show

...
05/13/2021  02:07 PM    <JUNCTION>     portal-web-timeline [path_to_lib\portal-web-timeline]

==== Original READMe.md ====

Demo

Install

# with npm
npm install react-timelines

# or with Yarn
yarn add react-timelines

Use

import Timeline from 'react-timelines'

const MyWidget = () => <Timeline {...props} />

export default MyWidget

Styling

Using Webpack

Using Webpack with CSS loader, add the following:

import 'react-timelines/lib/css/style.css'

Using Sass (SCSS)

Using Sass you can configure the timeline with variables:

$react-timelines-font-family: MaryAnn;
$react-timelines-sidebar-width: 320px;

@import '~/react-timelines/src/scss/style';

Without build tools

Create a CSS file with the contents of react-timelines/lib/css/style.css and include it in <head>

Development

npm install
npm run watch

This library is developed using VSCode - opening it in VSCode will recommend extensions, and enable linting and auto-formatting of code.