Skip to content

aviate-labs/core.mo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Core Libraries for Motoko

The core library is a curated collection of libraries designed to enhance and extend the functionality of the Motoko programming language. This repository aims to provide robust and efficient tools that are essential for building various applications in Motoko.

Content Table

Current Libraries

CBOR (Concise Binary Object Representation)

The CBOR library provides functions to encode and decode data in CBOR format, which is a compact data format designed for efficient data exchange.

import CBOR "mo:core/cbor/CBOR";

let value = encode(#TextString("Hello world!"));
// "\6C\48\65\6C\6C\6F\20\77\6F\72\6C\64\21"

Read more...

Certified Variables

Canister smart contracts can declare variables as certified. Whenever set, these variables will automatically get a Merkle tree certificate, signed by the Internet Computer blockchain. This allows anyone to verify the authenticity of this type of data using the Internet Computer's public key.

Read more...

Crypto

The Crypto library offers a collection of cryptographic functions and utilities, enabling secure data handling and operations within Motoko applications.

Read more...

SHA256

The SHA256 submodule provides a robust SHA-256 hashing function, crucial for creating secure digital fingerprints of data.

import SHA256 "mo:core/crypto/SHA256";

let hash = SHA256.sum(Blob.toArray(Text.encodeUtf8("Hello, world!")));

Encoding

The Encoding library includes various encoding schemes necessary for data manipulation and storage within Motoko applications.

Read more...

Binary

The Binary submodule allows for straightforward encoding and decoding of binary data, facilitating binary data handling in a variety of applications.

Hex

The Hex submodule provides functionalities to encode data into hexadecimal format and decode it back, which is useful for debugging and logging.

About

Core Libraries for Motoko

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Releases

No releases published

Languages