No description, website, or topics provided.
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.vscode
packages
scripts
types
.gitignore
.nvmrc
.prettierignore
.prettierrc
.yarnrc
README.md
cutting.code-workspace
package.json
pkg.js
tsconfig.base.json
tslint.json
yarn.lock

README.md

Cutting Monorepo

Prerequisites

  1. Install Node.js from http://nodejs.org or from your favorite package manager. At least version 9.3 is required.
  2. Yarn is used over NPM, mainly for the Yarn workspaces feature, installation instructions can be found here. At least Yarn version 1.5.0 is required for yarn workspaces.

There are initially 4 subpackages supporting the main meridian parent package all running under a @cutting scoped yarn package name:

  1. @cutting/devtools - Common webpack, jest and npm scripts
  2. @cutting/react-typed-mousetrap - Declaratively manage shortcuts on react components.
  3. @cutting/util - Any common functionality applicable to all packages can be found here.
  4. @cutting/react-scroll - Scroll to any component or scroll the window.
  5. @cutting/component-library - Common react components that can be shared among all projects. This ensures consistency in both styling and functionality. The atomic design methodology will be used to add a logical grouping to the component structure.
  6. @cutting/connected-components - Redux is the defacto state management solution for react at this time of writing and any common redux functionality can be found here.
  7. @cutting/website - Frontend main site code for the cutting website

Each subpackage above can be deployed or imported as an npm package in isolation.

All packages have tests and most part from util have their own viewable demo webserver to display the current functionality.

Installation instructions

To check everything is working locally, run the following commands:

yarn install
yarn start

When these commands have finished open a browser at http://localhost:3000

Run tests

A combination of the test runner jest and enzyme are used to unit test the code.

You will need to have perviously ran yarn install before running:

yarn test

This will run unit tests in every subpackage of the yarn workspace. Each subpackage has its own suite of tests that can be executed with the same command when executed in the subdirectory.