Skip to content

CoorpAcademy/components

Folders and files

NameName
Last commit message
Last commit date
Nov 26, 2018
Jan 17, 2023
May 29, 2024
Oct 5, 2022
Mar 26, 2025
Apr 22, 2024
Jun 29, 2022
Apr 9, 2024
Nov 23, 2022
Apr 22, 2024
Oct 22, 2024
Jul 18, 2017
Mar 27, 2025
Nov 4, 2019
Oct 25, 2017
Apr 9, 2024
Jul 20, 2022
Dec 20, 2018
May 20, 2020
Sep 17, 2019
Oct 22, 2024
Feb 6, 2025

Repository files navigation

Coorpacademy Components

Build Status Coverage Status GitPitch lerna

Static demos

If you want to see what theses packages have to look there: πŸ˜‰

Packages

How to

Start:

source scripts/setup.sh
yarn
yarn prepare # or 'npm run prepare'

You might need to source scripts/setup.sh to notably to load the fontawesome token in the FONTAWESOME_NPM_AUTH_TOKEN env variable.

Publish:

See detailed doc

Add a new dependency:

Go to the target package, and add the dependency using

yarn add myPackage

install dependencies for a specific package:

lerna add dependency-name --scope=package-name

run a specific test file:

lerna run --scope @coorpacademy/components test:unit -- test/file/path
# lerna accept globs for packages, ex "@coorpacademy/redux-*"

You'll need -W (aka --ignore-workspace-root-check) to install to package root.

Unit Tests with eslint and ava:

You can either invoke it at the monorepo top level, or in specific packages

npm test
# or if you just run lint
npm run lint
# or tests
npm run test:unit

Developing apps using HMR and components

For recap, HMR stands for Hot Module replacement

[@coorpacademy-components]> npm run build:es -- --watch
[@coorpacademy-app-player]> npm start

Troubleshooting

dependencies

Lerna is used to plug and publish all the packages in this repo. You may have to reset all node_modules : use lerna clean before performing npm i again.

publishing

Be sure your packages are public, or you'll end up with errors on CI like.

Extracting tar content of undefined failed, the file appears to be corrupt: "Unexpected end of data"

set your public access:

> npm access public @coorpacademy/progression-engine

For others publishing issues see dedicated section in Publish doc

flow

If you have any problem during an npm run build command related to flow: `

  • Kill flow processes
    pkill -f flow
  • Check if the problem is related to a new installed dependency. In this case, exclude the dependency on the .flowconfig file.