# @pschaubroeck/ui-framework

> ui-framework component library based on bootstrap

Latest version **1.1.0** (published 2020-10-11) · ISC license · 0 weekly downloads

## Install

```sh
npm install @pschaubroeck/ui-framework
pnpm add @pschaubroeck/ui-framework
yarn add @pschaubroeck/ui-framework
bun add @pschaubroeck/ui-framework
```

## Health

**Score 20/100 (F)** — status: abandoned.

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.1.0 |
| Published | 2020-10-11 |
| First published | 2020-10-02 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 3 |
| Unpacked size | 2.4 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | developer@businessolver.com |
| Maintainers | pschaubroeck |

## Links

- npm: https://www.npmjs.com/package/@pschaubroeck/ui-framework
- npm.io page: https://npm.io/package/@pschaubroeck/ui-framework

## Dependencies (3)

- [react-bootstrap](https://npm.io/package/react-bootstrap.md) ^1.0.1
- [react-hook-form](https://npm.io/package/react-hook-form.md) ^6.2.0
- [react-datepicker](https://npm.io/package/react-datepicker.md) ^2.16.0

## Recent versions

- 1.1.0 (latest) — 2020-10-11
- 1.0.0 — 2020-10-02

## README

# UI Framework

UI Framework is a wrapper for [react-bootstrap](https://react-bootstrap.netlify.app/) using themed [Bootstrap 4](https://getbootstrap.com/) css, created as re-useable/accessible components for BusinesSolver react applications.

[Live Documentation](https://bamboo.businessolver.com/browse/UI-UIF/latest/artifact/shared/static_storybook/index.html)

## What's New

-   v1 - initial components/documentation

## Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

### Notable Dependencies

-   [react-bootstrap](https://react-bootstrap.netlify.app/)
-   [react-datepicker](https://github.com/Hacker0x01/react-datepicker/)
-   [react-hook-form](https://react-hook-form.com/)
-   [Storybook](https://www.learnstorybook.com/)

### Coding style

`eslint`, `stylelint`, and `Prettier` are setup in the project. Even if you have the code formatted ugly, prettier will format the code for you.

-   Git hooks are pre-setup, `eslint`, `stylelint`, and `Prettier` will run automatically on commit.
-   Running eslint/stylelint manually:

    ```terminal
    cd <project directory>
    npm run lint
    ```

-   Running Prettier manually:
    ```terminal
    cd <project directory>
    npm run format
    ```

## Installing

After cloning the project, run the following command(s)

-   install project dependencies
    ```terminal
    cd <project directory>
    yarn
    ```

## Running the app locally

```terminal
cd <project directory>
npm run storybook
```

## Unit Tests

Unit testing uses a combination of `jest`, and `enzyme`. Test files should be packaged with the components themselves, and end with a `.test.js` suffix.

### Test Structure

-   Component
    -   defaultProps
        -   tests validity of default props
        -   tests validity of custom props
    -   Data types
        -   tests validity of PropTypes
    -   Events
    -   Conditionals
        -   tests for conditional rendering/logic inside components
    -   States
        -   tests various component states

### Running Tests

-   All tests

    ```terminal
    cd <project directory>
    npm run test
    ```

-   Running single test files

    ```terminal
    cd <project directory>
    npm run test -- <file prefix>.test.js
    ```

-   Debugging tests with console.log
    -   need to set `verbose` flag to false
    -   ex) `npm run test -- --verbose=false`

## Builds for deployment

Deployments consist of

-   the component library
    -   the component files
    -   bootstrap themed css file
-   a static storybook to be hosted externally from the library itself.

```terminal
cd <project directory>
npm run format:build
npm run lint:build
npm run build
npm run storybook:build
npm run test:coverage
```

---
_Source: https://npm.io/package/@pschaubroeck/ui-framework · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
