npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

pw-react-component-library-mui5

v2.0.8

Published

React component library for Optimal Compliance

Downloads

2

Readme

Optimal Compliance React Component Library

React component library used in Optimal Compliance React projects

Installation

Use npm to install.

npm install @oc-digital/react-component-library

or yarn

yarn add @oc-digital/react-component-library

Peer dependencies

  "react": ">=17.0.0",
  "react-dom": ">=17.0.0",
  "@material-ui/core": "=4.12.3",
  "@material-ui/icons": "=4.11.2",
  "react-router-dom": ">=5.0.0",
  "@date-io/date-fns": "=1.3.13",
  "date-fns": "=2.25.0",
  "react-number-format": "=4.8.0",
  "@material-ui/pickers": "=3.3.10",
  "yup": "=0.32.11",
  "react-table": "=7.7.0",
  "@material-ui/lab": ">=4.0.0-alpha.60",
  "lodash": "^4.17.21",

Usage

import React from "react";
import { Button } from "@oc-digital/react-component-library";

const ReactComponent = () => (
  <Button onClick={() => console.log("Clicked me!")}>Click Me!</Button>
);

Local Usage

1. increment the package version and add -beta.0 (e.g. 2.0.6 => 2.0.7-beta.0) and run npm install
    1a. if you need to further increment and publish use -beta.1, -beta.2 and so on
    1b. you can use this all in one command for the above - npm version 2.0.7-beta.0
2. publish the component library with command - npm publish --tag beta
3. pin the version in the receiving library to "=2.0.7-beta.0" and run npm install
4. once happy with the changes remove -beta.0 part and part and publish component library
    4a. update the version in the receiving library to "^2.0.7"

Building and publishing

To publish new version login using npm login, increment version in package.json and run npm publish. Subsequently it will build the library to build folder and push it's contents to the npm.

Local Usage(OLD DEPRECATED)

You can use this library locally, however few steps are required:

In the root of component library:

  1. install npm install and build npm run build component library
  2. remove node_modules folder
  3. run npm link

In the receiving project:
4. run npm link @oc-digital/react-component-library 5. start the project npm start - this should compile project with local version of component library 6. wait for npm start to finish and run npm i inside component react-component-library to restore node modules (this prevents numerous typing issues in the receiving project)

To make further adjustments in the component library:

  1. run npm install
  2. make code adjustments
  3. run npm build

When finished with adjustments you need to unlink local component library with:
npm unlink @oc-digital/react-component-library --no-save

Helper Scripts available in the project:
npm run useLocalLib - does initial step 1 to 4
npm run unlinkLib - does unlinking

Playground

Use storybook to explore components

npm run storybook