Skip to content

Latest commit

 

History

History
67 lines (39 loc) · 1.9 KB

File metadata and controls

67 lines (39 loc) · 1.9 KB

Contributing Guide

Overview

This repository employs a monorepo setup with pnpm workspaces, and hosts a number of associated but separated packages.

  • The plugins directory contains all the official plugins.
  • The themes directory contains all the official themes.

Development Setup

Pre-requirement:

Clone the repo, and install dependencies:

pnpm install

Build source code:

pnpm run bundle

Run unit tests:

pnpm run test

Main tools that used in this project:

Scripts

pnpm run bundle

The bundle script uses tsdown to compile TypeScript source files to JavaScript dist files.

Also, it will copy necessary resources from source directory to dist directory, because some source files (e.g. .vue, .css files) would not be processed by tsc, but should keep the same relative path in the dist directory.

You may need to run this script first after your clone this repository, because the dist files are ignored by .gitignore.

pnpm run clean

The clean script runs clean script in all packages, cleaning all the dist files and caches. In other words, it will remove all the files that generated by bundle script.

It's used before you want to re-build source files from a clean / initial state.

pnpm run format

The format script uses oxfmt to format all source files.

pnpm run lint

The lint script uses OxLint to check all source files.

pnpm run test

The test script uses Vitest to run unit testings.