https://github.com/dfinity/motoko
Simple high-level language for writing Internet Computer canisters
https://github.com/dfinity/motoko
internet-computer motoko motoko-language programming-language
Last synced: 15 days ago
JSON representation
Simple high-level language for writing Internet Computer canisters
- Host: GitHub
- URL: https://github.com/dfinity/motoko
- Owner: dfinity
- License: apache-2.0
- Created: 2018-05-11T11:12:10.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2024-05-23T08:56:20.000Z (11 months ago)
- Last Synced: 2024-05-23T09:40:39.734Z (11 months ago)
- Topics: internet-computer, motoko, motoko-language, programming-language
- Language: OCaml
- Homepage:
- Size: 37.4 MB
- Stars: 486
- Watchers: 43
- Forks: 98
- Open Issues: 454
-
Metadata Files:
- Readme: README.md
- Changelog: Changelog.md
- Contributing: .github/CONTRIBUTING.md
- License: LICENSE
- Code of conduct: .github/CODE_OF_CONDUCT.md
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
- awesome-internet-computer - Motoko GitHub Repository - The home of the Motoko language. (Motoko / Monitoring)
- best-of-crypto - GitHub - 39% open · ⏱️ 27.05.2024): (Metaverse, NFTs & Gaming)
README
# [Motoko](https://internetcomputer.org/docs/current/motoko/main/about-this-guide) · [](https://opensource.org/licenses/Apache-2.0) [](https://github.com/dfinity/motoko/actions?query=workflow:"release") [](https://github.com/dfinity/motoko/blob/master/.github/CONTRIBUTING.md)
A safe, simple, actor-based programming language for building [Internet Computer](https://internetcomputer.org/) (ICP) canister smart contracts.

## User Documentation & Samples
* [Introduction](https://internetcomputer.org/docs/current/motoko/main/getting-started/motoko-introduction)
* [Basic concepts and terms](https://internetcomputer.org/docs/current/motoko/main/getting-started/basic-concepts)
* [Sample code](samples)
* [Language manual](doc/md/reference/language-manual.md)
* [Concrete syntax](doc/md/examples/grammar.txt)
* [Documentation sources](doc/md/)
* [Base library documentation](doc/md/base/index.md)
* [_Motoko-san_: a prototypical deductive verifier](src/viper/README.md)## Introduction
### Motivation and Goals
* High-level programming language for ICP smart contracts
* Simple design and familiar syntax
* Convenient support for the [actor model](https://en.wikipedia.org/wiki/Actor_model)
* Good fit for underlying Wasm and ICP execution model
### Key Design Points
* Object-based language with actors, classes, modules, etc. as closures
* Classes can be actors
* Async construct for direct-style programming of asynchronous messaging
* Structurally typed with simple generics and subtyping
* Overflow-checked number types, explicit conversions
* JavaScript/TypeScript-style syntax but without the JavaScript madness
* Inspirations from Java, C#, JavaScript, Swift, Pony, ML, Haskell
## Related Repositories
* [Base library](https://github.com/dfinity/motoko-base)
* [Vessel package manager](https://github.com/dfinity/vessel)
* [Example projects](https://github.com/dfinity/examples/tree/master/motoko)
* [ICP Ninja, online authoring of canisters](https://icp.ninja)
* [Motoko Playground](https://github.com/dfinity/motoko-playground) · (DEPRECATED — [online IDE](https://play.motoko.org))
* [Embed Motoko code snippets](https://github.com/dfinity/embed-motoko) · ([online interpreter](https://embed.smartcontracts.org/))
* [VS Code extension](https://github.com/dfinity/vscode-motoko) · ([install](https://marketplace.visualstudio.com/items?itemName=dfinity-foundation.vscode-motoko))
* [Browser and Node.js bindings](https://github.com/dfinity/node-motoko) · ([npm package](https://www.npmjs.com/package/motoko))## Community Resources
* [Awesome Motoko](https://github.com/motoko-unofficial/awesome-motoko#readme)
* [Blocks - an online low-code editor for Motoko](https://github.com/Blocks-Editor/blocks)
* [MOPS - a Motoko package manager hosted on the IC](https://j4mwm-bqaaa-aaaam-qajbq-cai.ic0.app/)
* [Motoko Bootcamp](https://github.com/motoko-bootcamp/bootcamp#readme) · ([YouTube channel](https://www.youtube.com/channel/UCa7_xHjvOESf9v281VU4qVw))
* [Motoko library starter template](https://github.com/ByronBecker/motoko-library-template)## Contributing
See our [contribution guidelines](.github/CONTRIBUTING.md), [code of conduct](.github/CODE_OF_CONDUCT.md) and [build instructions](Building.md) to get started.