pr0x2b / solidity-by-example.github.io

Solidity By Example

Home Page:https://solidity-by-example.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

solidity-by-example.github.io

Solidity By Example

License

MIT License

Memo

  • Uses 404.html to re-route all URL to client side router in index.html
## Deploy ##
# md to react
npx ts-node --project ./scripts/tsconfig.json scripts/md-to-react.ts src/pages/array

# md to react all pages
find src/pages -type d -not -path "*/__snapshots__" -exec npx ts-node --project ./scripts/tsconfig.json scripts/md-to-react.ts {} \;

# build routes
npx ts-node --project ./scripts/tsconfig.json scripts/build-routes.ts

# deploy
npm run deploy

## Compile Solidity ##
solc-select install 0.8.10
solc-select use 0.8.10

# compile single file
solc src/pages/hello-world/HelloWorld.sol

# find and compile sol
find src/pages/hacks -name "*.sol" solc {} \;

## Mics ##
# rename files
find . -type f -name "index.test.js" -exec sh -c 'mv "$0" "${0%.test.js}.test.tsx"' {} \;

About

Solidity By Example

https://solidity-by-example.org/

License:MIT License


Languages

Language:TypeScript 79.1%Language:Solidity 19.6%Language:CSS 0.9%Language:HTML 0.3%Language:Mustache 0.1%