Edge & Node Common
This project implements and contains common utils and models/types to be ingested and utilized by other Edge & Node repos.
Building and running
- Run
yarn
to install all dependencies. - Run
yarn build
to bundle all files using rollup - Run
yarn publish
to publish to NPM
Testing
This repo uses jest
for its test suite/runner. To run the tests:
yarn test
Local development
- Run
yarn link
inside of this folder - Run
yarn link @edgeandnode/components
inside of another application that includes components in local development
Directory Structure and Naming Convention
All source code belongs in the src
directory. Inside of this directory, it is broken up by domain (ex: utils
) and all files in the domain directory should contain code that matches that domain (ex: graphql.utils.ts
). File names should be kebob-case
and have the file domain type appended with a .
before the file extension (i.e. all files in src/utils
should be follow {utils-type}.utils.ts
. ex: graphql.utils.ts
). Test files belong at the same level as the file they are putting under test and should follow the same naming convention as the file they are putting under test with .test
appended before the file extension (i.e. {utils-type}.utils.test.ts
. ex: graphql.utils.test.ts
).