@stjudecloud/ui-react
v5.1.19
Published
React implementation for St. Jude Cloud Theme components
Downloads
50
Keywords
Readme
Quick Start
Use the following commands to get started quickly.
# Clone the repository and cd to packages/react
git clone https://github.com/stjudecloud/theme.git
cd theme/packages/react
# Install dependencies
npm install
# Build the library as ESM and CommonJS
npm run build
# Run a storybook instance to interactively develop components
npm run storybook
Versioning
This repository matches Bootstrap's two major version numbers. If this repository's version is v4.3.123, then it depends on Bootstrap v4.3.x.
Using this package
First, add the library to your package.json
:
npm add @stjudecloud/theme-react
Next, use any of the components provided by the library in your own designs.
import {Navbar} from '@stjudecloud/ui-react';
function MyComponent() {
return (
<div>
<Navbar {...props} />
Cool content
</div>
);
}
PLEASE NOTE: Your build process will need to be able to handle importing image files, e.g. with webpack
+ file-loader
.
Optional Dependencies (react-router-dom)
Originally, react-router-dom was listed as an optional dependency. However, it turns out that NPM does not actually skip optional dependencies. For this reason. it is declared as a peer dependency, but is correctly handled if the dependency is missing.
Copyright
© 2021-Present St. Jude Children's Research Hospital.