Skip to content

dfinity/motoko-core

Repository files navigation

core


The core package is the official standard library for the Motoko programming language.

This replaces the original base library, which is available here.

An official migration guide is available for upgrading projects from base to core.

Quick Start

  1. Install the Mops package manager
  2. Open a terminal in your project directory
  3. Run mops add core

This adds the following dependency to your mops.toml config file:

[dependencies]
core = "0.6.0"

Contributing

PRs are welcome! Please check out the contributor guidelines for more information.

Interface design and code style guidelines for the repository can be found here.

Dev Environment

Make sure that Node.js >= 22.x is installed on your system.

Run the following commands to configure your local development branch:

# First-time setup
git clone https://github.com/dfinity/motoko-core
cd motoko-core
npm ci
npx ic-mops toolchain init

Below is a quick reference for commonly-used scripts during development:

npm test # Run all tests
npm run format # Format Motoko files
npm run validate:api # Update the public API lockfile
npm run validate:docs Array # Run code snippets in `src/Array.mo`

All available scripts can be found in the project's package.json file.

Major Contributors

Big thanks to the following community contributors:

About

The official standard library for Motoko.

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Contributors 12