1.0.0-beta.20 • Published 7 years ago

cb-component-library v1.0.0-beta.20

Weekly downloads
3
License
MIT
Repository
github
Last release
7 years ago

Caring Bridge Component Library

Compilation of Reusable Components

Getting Started

Obtain the publishing token if you need to publish updates to npm

from the home folder

sudo nano .bash_profile

add the following: export NPM_TOKEN="00000000-0000-0000-0000-000000000000"

save and exit

source .bash_profile

Setup environment variable on OSX

Initial Run

If you are not using yarn install

npm install -g yarn

Get the latest

yarn install

Update your test snapshots

yarn test -u

Load the Storybook

yarn storybook

Useful Extensions

  • Chrome Debug - Microsoft
  • ESLint - Dirk Baeumer
  • TSLint - egamma
  • Typescript React Code Snippets - infeng
  • npm intellisense - Christian Kohler
  • npm - egamma

Debuging

This should allow for breakpoints to set when developing components.

1) Intall Chrome Debug Extension

>  Chrome Debug - Microsoft

2) Select Debug -> Start Debugging from main menu.

This will create a new file if not present under the `.vscode` folder called `launch.json`.

3) Configure Chome Debug

Usually the port used for storyboard is `9001`
Fix webRoot to use `${workspaceFolder}/src`.

Your configure should look similar to this:


    {
        "type": "chrome",
        "request": "launch",
        "name": "Launch Chrome against localhost",
        "url": "http://localhost:9001",
        "webRoot": "${workspaceFolder}/src"
    }

Install Component Library

yarn add cb-component-library react react-dom @fortawesome/fontawesome-svg-core @fortawesome/free-solid-svg-icons @fortawesome/react-fontawesome

Navigation

  • TaskBar