react-npm-formatted-relative-date
Basic React app. This project just aim to display relative date.
Features
- Display Realative date.
- Runs in the browser and Node.js.
- Built on standards.
Example
;;; { superprops; } { let myDate = 2016625; return <div> <FormattedRelativeDate date=myDate /> </div> ; } ReactDOM;
This example would render: relative date i.e. 3 days ago into the container element on the page.
Technology Stack:
- react
- mocha
- react-intl
Usage:
Clone the repo as a new project:
git clone https://github.com/lobdev/react-npm-formatted-relative-date.git <formatted-relative-date>
Start Server:
First you have to replace the lib/component/formatted-relative-date.js to server.js in package.json
cd formatted-relative-date
npm i
npm start
Run App:
npm start command automatically initiate browser at 3000 port
http:://localhost:3000
Run tests:
cd formatted-relative-date
npm i
npm test
Developer Notes:
Make sure you configure your editor/IDE to use:
.editorconfig
.eslintrc