2.1.0 • Published 5 years ago

@tffg/emn-lib-components v2.1.0

Weekly downloads
-
License
UNLICENSED
Repository
github
Last release
5 years ago

equipMe now React Component Library

A React component library for the equipMe now client applications built using NWB. Before getting started read here about Developing React Components and Libraries with nwb.

This project can be published to the TFFG NPM account, allowing components to easily be added to other projects.

Getting Started

You'll need nodejs and yarn installed.

Clone repo:

git clone git@github.com:tffg/emn-lib-components.git

Install dependencies:

yarn install

Scripts

package.json is configured with "scripts" we can use with yarn run while developing the project.

CommandDescription
yarn startstart a development server for the demo app
yarn testrun tests
yarn test:coveragerun tests and produce a code coverage report in coverage/
yarn test:watchstart a test server and re-run tests on every change
yarn buildprepare for publishing to npm
yarn cleandelete built resources

Running the Demo App

The project includes a demo app in demo/src/index.js. When new components are created, they can be added to this demo app to preview how component will look and behave.

Running yarn start will start a development server for the demo app. Every time you make a change to the demo app or any component, it will refresh the current compilation status. Running yarn build will also buid a production version of the demo app which could deployed if desired.

Publishing to npm

Once you've built your project, it's ready for publishing to npm:

yarn publish

You must first be logged into the TFFG NPM account by running yarn login.

Local Testing

Ideally there would be tests written for each component, however since this may not always happen as it should it is also possible to do integration testing with the consuming application by creating a local symlink on your machine.

Within the emn-lib-components directory run:

yarn link

Then within the consuming application run:

yarn link "@tffg/emn-lib-components"

Now you whenever you run yarn build on emn-lib-components the consuming application will update with the latest changes.

2.1.0

6 years ago

2.0.0

6 years ago

1.6.4

6 years ago

1.6.3

6 years ago

1.6.2

6 years ago

1.6.1

6 years ago

1.6.0

6 years ago

1.5.1

6 years ago

1.5.0

6 years ago

1.4.6

6 years ago

1.4.5

6 years ago

1.4.4

6 years ago

1.4.3

6 years ago

1.4.2

6 years ago

1.4.1

6 years ago

1.4.0

6 years ago

1.3.0

6 years ago

1.2.2

6 years ago

1.2.1

6 years ago

1.2.0

6 years ago

1.1.4

6 years ago

1.1.3

6 years ago

1.1.2

6 years ago

1.1.1

6 years ago

1.1.0

6 years ago

1.0.0

6 years ago