Skip to content

Repository files navigation

Micra

DocumentationContributingCode of Conduct

issues prs

About

Micra's monorepo

Development

Code Quality

Linting

pnpm check

Auto Formatting

pnpm format

Testing

pnpm test

Updating Dependencies

pnpm dependencies:update

Versioning

Creating a Changeset

Whenever a change is made to one of the packages, a changeset should be created. This can be done by running:

pnpm version:bump

Documentation

Generating Reference Documentation

To generate the reference documentation, run:

pnpm docs:generate

Scaffolding

This monorepo is setup with scaffolding capabilities. To scaffold, run:

pnpm generate {generator}

Scaffold an New Framework Specification

pnpm generate spec

Scaffold a new library

pnpm generate library

Library file generators

In the library folder you can generate the following files:

Scaffold a new class file

To add a new class file to a library, run:

pnpm generate class

This will create a new file in the ./packages/[library]/src/classes folder.

Scaffold a new constants file

To add a new constants file to a library, run:

pnpm generate constants

This will create a new file in the ./packages/[library]/src/constants folder.

Scaffold a new guard file

To add a new guard file to a library, run:

pnpm generate guard

This will create a new file in the ./packages/[library]/src/guards folder.

Scaffold a new submodule

To add a new submodule to the library, run:

pnpm generate submodule

This will create a new file in the ./packages/[library]/src/[name].ts and update the package.json, vite.config.ts and the main src/index.ts files to include the new submodule.

Scaffold a new types file

To add a new types file to a library, run:

pnpm generate types

This will create a new file in the ./packages/[library]/src/types folder.

Scaffold a new utility file

To add a new utility file to a library, run:

pnpm generate utility

This will create a new file in the ./packages/[library]/src/utilities folder.

Creating a Custom Generator

To create a custom generator, edit the ./turbo/generators/config.ts file and add a new generator via the plop.setGenerator method. Under the hood, we use Turborepo's gen package which uses Plop to generate files. Take a look at their documentation to learn more about how to create custom generators. To write your code, make sure to check out the ./turbo/generators/utilities folder for helper functions.

Contributors

About

A modular JavaScript framework for building scalable applications.

Resources

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Used by

Contributors

Languages