All Projects โ†’ solidstate-network โ†’ solidstate-solidity

solidstate-network / solidstate-solidity

Licence: MIT license
๐Ÿ’  Upgradeable-first Solidity smart contract development library ๐Ÿ’ 

Programming Languages

typescript
32286 projects
solidity
1140 projects

Projects that are alternatives of or similar to solidstate-solidity

hardhat-abi-exporter
๐Ÿงฐ Export Solidity contract ABIs on compilation โš™๏ธ
Stars: โœญ 29 (-89.02%)
Mutual labels:  wow, smart-contracts, eth, ether, buidler, hardhat
hardhat-dependency-compiler
๐Ÿ“ฆ Compile Solidity sources directly from NPM dependencies
Stars: โœญ 19 (-92.8%)
Mutual labels:  wow, smart-contracts, buidler, hardhat
hardhat-contract-sizer
Output Ethereum contract sizes with Hardhat ๐Ÿ“
Stars: โœญ 55 (-79.17%)
Mutual labels:  wow, smart-contracts, buidler, hardhat
erc721
The reference implementation of the ERC-721 non-fungible token standard.
Stars: โœญ 989 (+274.62%)
Mutual labels:  smart-contracts, eth
create-ether-dapp
A template for building Full-Stack Blockchain Dapps using Next.js (React), TypeScript, Tailwind CSS, Hardhat, Solidity, and many more!
Stars: โœญ 100 (-62.12%)
Mutual labels:  smart-contracts, hardhat
framework
Lightweight, open source and magic-free framework for testing solidity smart contracts.
Stars: โœญ 36 (-86.36%)
Mutual labels:  smart-contracts, eth
ethereum-dex
Decentralized exchange implementation for the 0xcert protocol on the Ethereum blockchain.
Stars: โœญ 18 (-93.18%)
Mutual labels:  smart-contracts, eth
Ethereum Erc721
Non-fungible token implementation for Ethereum-based blockchains.
Stars: โœญ 253 (-4.17%)
Mutual labels:  smart-contracts, eth
typescript-eth-starter
๐Ÿ”Œ Ethereum Dapp Basic Typescript Starter
Stars: โœญ 125 (-52.65%)
Mutual labels:  smart-contracts, hardhat
Web3j
Lightweight Java and Android library for integration with Ethereum clients
Stars: โœญ 3,537 (+1239.77%)
Mutual labels:  smart-contracts, ether
Simple-Game-ERC-721-Token-Template
๐Ÿ”ฎ Very Simple ERC-721 Smart Contract Template to create your own ERC-721 Tokens on the Ethereum Blockchain, with many customizable Options ๐Ÿ”ฎ
Stars: โœญ 83 (-68.56%)
Mutual labels:  smart-contracts, eth
ethereum-erc20
Fungible token implementation for the Ethereum blockchain.
Stars: โœญ 27 (-89.77%)
Mutual labels:  smart-contracts, eth
ethereum-crowdsale
0xcert protocol crowdsale contracts for Ethereum blockchain.
Stars: โœญ 15 (-94.32%)
Mutual labels:  smart-contracts, eth
web3scala
Scala library for integration with Ethereum clients
Stars: โœญ 24 (-90.91%)
Mutual labels:  smart-contracts, ether
Eth Crypto
Cryptographic javascript-functions for ethereum and tutorials to use them with web3js and solidity
Stars: โœญ 420 (+59.09%)
Mutual labels:  smart-contracts, eth
contracts
Off-the-shelf Solidity smart contracts
Stars: โœญ 100 (-62.12%)
Mutual labels:  smart-contracts, hardhat
zeneth
๐Ÿต๏ธ Let Your ETH Chill โ€” Gasless Ethereum account abstraction with Flashbots
Stars: โœญ 112 (-57.58%)
Mutual labels:  smart-contracts, eth
v1-contracts
๐ŸUniswap V1 smart contracts
Stars: โœญ 430 (+62.88%)
Mutual labels:  smart-contracts
DBM-Retail
The ultimate encounter helper (for Retail) to give you fight info that's easy to process at a glance. DBM aims to focus on what's happening to you, and what YOU need to do about it.
Stars: โœญ 194 (-26.52%)
Mutual labels:  wow
baseline
The Baseline Protocol is an open source initiative that combines advances in cryptography, messaging, and distributed ledger technology to enable confidential and complex coordination between enterprises while keeping data in systems of record. This repo serves as the main repo for the Baseline Protocol, containing core packages, examples, and rโ€ฆ
Stars: โœญ 565 (+114.02%)
Mutual labels:  smart-contracts

SolidState Solidity

SolidState is an upgradeable-first Solidity smart contract development library.

It consists of the following packages:

package description ๐Ÿ“•
@solidstate/abi contract ABIs ๐Ÿ“–
@solidstate/contracts core contracts ๐Ÿ“–
@solidstate/library functions for interacting with and validating contracts ๐Ÿ“–
@solidstate/spec portable tests which may be run against third-party implementations of core contracts ๐Ÿ“–

Note: A version of this library has been audited by Hacken. More details are available in the report.

Contracts

All contracts are designed to either be deployed through the standard constructor method, or referenced by a proxy. To this end, the diamond storage pattern is employed exclusively.

Spec

Where possible, automated tests are designed to be imported by repositories which make use of the SolidState contracts and run against any derived contracts. This is to help prevent unintended changes to to the base contract behavior.

For example, consider a custom ERC20Base implementation:

import '@solidstate/contracts/token/ERC20/base/ERC20Base.sol';

contract CustomToken is ERC20Base {
  // custom code...
}

Rather than rewrite the ERC20Base tests or assume that all core behavior remains untouched, one can import the included tests and run them against the custom implementation:

describe('CustomToken', function () {
  let instance;

  beforeEach(async function () {
    const factory = await ethers.getContractFactory('CustomToken');
    instance = await factory.deploy();
    await instance.deployed();
  });

  describeBehaviorOfERC20Base(
    {
      deploy: () => instance,
    },
    [],
  );

  // custom tests...
});

If parts of the base implementation are changed intentionally, tests can be selectively skipped:

describeBehaviorOfERC20Base(
  {
    deploy: () => instance,
  },
  ['#balanceOf'],
);

describe('#balanceOf', function () {
  // custom tests
});

Development

Install dependencies via Yarn:

yarn install

Setup Husky to format code on commit:

yarn prepare

Link local packages and install remaining dependencies via Lerna:

yarn run lerna bootstrap

Compile contracts via Hardhat:

yarn run hardhat compile

Automatically upgrade dependencies with yarn-up:

yarn upgrade-dependencies

Testing

Test contracts with Hardhat and generate gas report using hardhat-gas-reporter:

yarn run hardhat test

Generate a code coverage report using solidity-coverage:

yarn run hardhat coverage

Publication

Publish packages via Lerna:

yarn lerna-publish

Supporters

premia.finance

frexa.io

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].