Useful Materials
If you want to develop on Nervos CKB, it’s recommended that you learn some background knowledge. Here is a collection of all the materials that can help you to understand it. If you want to learn more about the design philosophy of Nervos, you can refer to the Nervos System Design
Data structure
Data Structures of Nervos CKB explains all of the basic data structures used in CKB, you can find the basic data structures and example used in CKB:
CKB Transaction structure
CKB Transaction is an essential data structure in CKB. We provide an RFC: CKB Transaction structure. The RFC contains two parts: the first one covers the core transaction features and the second one introduces some extensions. The details in this RFC maybe outdated, but still worth to read, you can check the newest transaction structure from the schema
Deposit and Withdraw in Nervos DAO
Deposit and Withdraw in Nervos DAO describes deposit and withdraw transactions in Nervos DAO with example. It’s very useful for developing Nervos DAO related features.
CKB Script Programming
Nervos CKB VM developer Xuejie Xiao has written a series of articles about CKB Script Programming. It’s very useful for developing scripts and applications that utilize CKB.
- Introduction to CKB Script Programming 1: Validation Model
- Introduction to CKB Script Programming 2: Script Basics
- Introduction to CKB Script Programming 3: UDT
- Introduction to CKB Script Programming 4: WebAssembly on CKB
- Introduction to CKB Script Programming 5: Debugging
Lockscript Samples
Currently, CKB has two lock scripts in the genesis block, The address code hash index 0x00
is for pay to pubkey hash and 0x01
is for pay to multisig, see RFC to learn details. You can refer to the samples:
Build CKB contract with Rust
Nervos CKB developer JJY has written a series of articles to explain that how to write a CKB contract in Rust and deploy it. We’ll see that the no_std
Rust actually is better than our first impression.