LogoLogo
WebsiteSubstrate Block ExplorerEVM Block ExplorerFaucet
  • Learn
    • Architecture
    • Staking
      • Proof of stake
    • Smart Contracts
    • Accounts
    • Infrastructure
      • Nodes
      • Agents
      • Models
      • IPFS
    • Security
      • OPOC
      • TSS
      • IPFS Integrity
      • Model Updates Integrity
    • Fees
    • Finney Testnet RPC Endpoints
  • Build
    • Address format
    • ink! Environment
    • Wasm Smart Contracts
      • Smart Contract Stack
      • Domain-Specific Languages (DSLs)
      • ink! Development
      • ask! Development
      • Basic ink! Contract
    • EVM Smart Contracts
      • Introduction to EVM Smart Contracts
      • HardHat
      • Your first EVM Smart Contract
      • Debug EVM Transactions
      • Precompiles
        • SR25519
        • Substrate ECDSA
        • XC20
    • Run a node
      • Run an archive node
        • Binary
      • Run a full node
      • Become a validator
        • Learn about Validators
        • Validator requirements
        • Spin up a validator
        • Set your identity
    • Build an Agent
      • Introduction
      • Development
      • Installing WASP
      • Agents API Reference
      • Available AI Models
Powered by GitBook
On this page
  • Understanding eDSLs
  • Available eDSLs
  • Choosing the Right eDSL
Export as PDF
  1. Build
  2. Wasm Smart Contracts

Domain-Specific Languages (DSLs)

Understanding eDSLs

Embedded Domain-Specific Languages (eDSLs) are specialized programming tools that enhance blockchain and smart contract development. These tools operate within existing programming languages, providing developers with a more intuitive and efficient way to write code.

💡 Key Benefit EDSLs allow developers to write smart contracts at a higher level of abstraction, making code more readable, maintainable, and less prone to errors.

Why Use eDSLs?

EDSLs offer several advantages for blockchain development:

  • More expressive and intuitive code writing

  • Built-in error checking mechanisms

  • Enhanced debugging capabilities

  • Specialized testing frameworks

  • Domain-specific optimizations

For example, rather than using pure Rust for Wasm smart contracts, developers can use specialized Rust eDSLs designed specifically for blockchain development, making the code more natural and easier to maintain.

Available eDSLs

ink!

ℹ️ What is ink!? ink! is a Rust-based eDSL developed by Parity Technologies, specifically designed for Substrate's pallet-contracts.

Key Features

  • Rust procedural macros support

  • Comprehensive crate ecosystem

  • Reduced boilerplate code

  • Direct integration with pallet-contracts API

Resources

ask!

🚧 Development Status ask! is a Polkadot treasury funded project currently under active development.

Overview

  • Framework for AssemblyScript developers

  • TypeScript-like syntax

  • Targets pallet-contracts for Wasm smart contracts

Resources

Choosing the Right eDSL

When selecting an eDSL for your project, consider:

  1. Programming Language Familiarity

    • ink! for Rust developers

    • ask! for TypeScript/AssemblyScript developers

  2. Project Requirements

    • Smart contract complexity

    • Performance needs

    • Team expertise

  3. Development Status

    • ink! is production-ready

    • ask! is under development

📚 Learn More For detailed information about using these eDSLs, refer to their respective documentation and GitHub repositories.

PreviousSmart Contract StackNextink! Development

Last updated 3 months ago

Official Documentation
GitHub Repository
API Reference
GitHub Repository
Treasury Proposal