difftreelog
Add instrcutions for re-enabling Ink! contracts
in: master
1 file changed
README.mddiffbeforeafterboth250### Check code style in tests250### Check code style in tests251```bash251```bash252cd tests && yarn eslint --ext .ts,.js src/252cd tests && yarn eslint --ext .ts,.js src/253```253```254255## Re-Enabling Ink! Contracts256257Uncomment following lies:2581. In node/rpc/Cargo.toml259```260# pallet-contracts-rpc = { version = "3.0", git = 'https://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.7' }261```2622632. In node/rpc/src/lib.rs264```265// C::Api: pallet_contracts_rpc::ContractsRuntimeApi<Block, AccountId, Balance, BlockNumber, Hash>,266...267// use pallet_contracts_rpc::{Contracts, ContractsApi};268...269// io.extend_with(ContractsApi::to_delegate(Contracts::new(client.clone())));270271```2722733. In runtime/Cargo.toml274```275 # 'pallet-contracts/std',276 # 'pallet-contracts-primitives/std',277 # 'pallet-contracts-rpc-runtime-api/std',278 # 'pallet-contract-helpers/std',279...280 # [dependencies.pallet-contracts]281 # git = 'https://github.com/paritytech/substrate.git'282 # default-features = false283 # branch = 'polkadot-v0.9.7'284 # version = '3.0.0'285286 # [dependencies.pallet-contracts-primitives]287 # git = 'https://github.com/paritytech/substrate.git'288 # default-features = false289 # branch = 'polkadot-v0.9.7'290 # version = '3.0.0'291292 # [dependencies.pallet-contracts-rpc-runtime-api]293 # git = 'https://github.com/paritytech/substrate.git'294 # default-features = false295 # branch = 'polkadot-v0.9.7'296 # version = '3.0.0'297...298 # pallet-contract-helpers = { path = '../pallets/contract-helpers', default-features = false, version = '0.1.0' }299```3003014. runtime/src/lib.rs302```303// use pallet_contracts::weights::WeightInfo;304...305// use pallet_contracts::chain_extension::UncheckedFrom;306...307// pub use pallet_timestamp::Call as TimestampCall;308...309// mod chain_extension;310// use crate::chain_extension::{NFTExtension, Imbalance};311...312/*313parameter_types! {314 pub TombstoneDeposit: Balance = deposit(315 ...316}317*/318...319//pallet_contract_helpers::ContractSponsorshipHandler<Runtime>,320...321// impl pallet_contract_helpers::Config for Runtime {}322...323// Contracts: pallet_contracts::{Pallet, Call, Storage, Event<T>},324...325// ContractHelpers: pallet_contract_helpers::{Pallet, Call, Storage},326...327//pallet_contract_helpers::ContractHelpersExtension<Runtime>,328...329/*330 impl pallet_contracts_rpc_runtime_api::ContractsApi<Block, AccountId, Balance, BlockNumber, Hash>331 for Runtime332 {333 ...334 }335*/336337```338