Agile Smart Contract Development Environment

$ 
✔ Ethereum development network running on port 8555
parasol> ✔ Compiled Token.psol:Token
Contract Token.psol:Token deployed at address 0x1a6b15Ea9d71b6A01C5EC718e27c2188F2454711

  Token.psol: Inline tests
    Transfer() should change balance after transfer  (238ms)
  Token.psol
      Transfer()
        should revert when transferred amount is smaller than 0

2 passing  (260ms)
parasol>  
{transactionHash:
'0xe6dd34e253c63421e0b1b29f696c2867613f81ed45a46cfeb8d75517c3febde4',
    transactionIndex: 0,
    blockHash:
      '0x8ec83f5c5dd78eca27f634f554b95035d9c34529d59bf5d628515cb143cdc963',
    blockNumber: 4
... }

Principles

Seperation of Concerns

Most existing development environments are designed for dApps, not for smart contracts. Developers are restricted to the Migration smart contracts design pattern as required by other development environments to facilitate ... dApp versioning. Parasol puts into consideration developers who intend to develop pure smart contracts and avoids restricting them to a specific dApp design pattern

Read more

Freedom

Parasol aims to implement as little abstraction on top of its dependencies as possible. It provides direct configuration access to its core components such as solc and ganache. Additionally, it allows the user the freedom ... to customize and contract deployment logic through the deployer() function in the configuration file.

Read more

Agility

Agile development is important for the entire smart contract development cycle, not only for the Solidity contracts themselves. In the realm of Solidity, unit tests can end up taking substantially longer to perfect than their ... source contracts. Hence, they consume more time. And then comes, documentation. In Parasol's development environment, any changes made to unit tests, smart contract source code or any js/json file will immediately and quickly recompile all code, run static analysis, redeploy on ganache, recompile documentation and rerun unit tests.

Read more

Instant zero-configuration contract
deployments using INFURA

Async-REPL Javascript session to
interact with deployed contracts & web3

Integrated Markdown contract
documentation using Natspec + ABI

Extended Mocha unit tests

Auto-recompiling, tests
& documentation on file change

Unopinionated design,
low design pattern restrictions

Built in Solidity Preprocessor

Features

Built-in Solidity Preprocessor

For more information

View on Github

Token.psol

pragma solidity ^0.4.24;

{{ strict = true }} // Activate strict mode. This will abort deployment on both errors and warnings.

/// @title {{= title }}
contract Token {

    // Variables retrieved from parasol.js config file pre compilation
    string private name = "{{= tokenName}}";
    string private symbol = "{{= tokenSymbol}}";
    uint8 private decimals = {{= tokenDecimals}};
    uint256 private totalSupply = {{= tokenSupply}}; 
    mapping (address => uint256) public _balances;
    event Transfer(address indexed _from, address indexed _to, uint256 _value);
    constructor() public {
        _balances[msg.sender] = totalSupply;
    }
    function transfer(address _to, uint256 _value) public returns (bool success) {
        ...
    {{    
        // inline mocha unit test
        test(this, 'Balance should change balance after transfer()', async function() {
            var preBalance = await contracts["Token.psol:Token"].methods.balanceOf(accounts[0]).call()
            await contracts["Token.psol:Token"].methods.transfer(accounts[1], 1).send()
            var postBalance = await contracts["Token.psol:Token"].methods.balanceOf(accounts[0]).call()
            assert.notEqual(preBalance, postBalance)
        })    
    }}
    // Preprocessor directive. Only compiles if in 'dev' network
    {{ if (network === "dev") { }}
        function forceTransfer(address _from, address _to, uint256 _value) public returns (bool success) {
            require(_balances[_from] >= _value);
            _balances[_from] -= _value;
            _balances[_to] += _value;
            emit Transfer(_from, _to, _value);
            return true;
        }
    {{ } }}

}

Getting Started

npm install -g parasol-clicopy
mkdir token && cd tokencopy
parasol initcopy
parasolcopy

Want to know more?

Read the Documentation