{"id":21588885,"url":"https://github.com/evmts/tevm-cast","last_synced_at":"2025-04-10T21:51:57.704Z","repository":{"id":257176831,"uuid":"857533969","full_name":"evmts/tevm-cast","owner":"evmts","description":"An example application of Tevm emulating the cast CLI in the browser","archived":false,"fork":false,"pushed_at":"2024-10-20T23:00:16.000Z","size":370,"stargazers_count":20,"open_issues_count":1,"forks_count":5,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-04-10T21:51:51.669Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://tevm-cast.vercel.app","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/evmts.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-09-14T22:37:47.000Z","updated_at":"2024-11-26T19:06:49.000Z","dependencies_parsed_at":"2024-09-15T06:27:39.396Z","dependency_job_id":"713977b1-3af7-46f3-b031-56e36976e618","html_url":"https://github.com/evmts/tevm-cast","commit_stats":null,"previous_names":["evmts/tevm-cast"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evmts%2Ftevm-cast","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evmts%2Ftevm-cast/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evmts%2Ftevm-cast/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evmts%2Ftevm-cast/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/evmts","download_url":"https://codeload.github.com/evmts/tevm-cast/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248305854,"owners_count":21081562,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-24T16:11:51.183Z","updated_at":"2025-04-10T21:51:57.662Z","avatar_url":"https://github.com/evmts.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Tevm Cast Clone\n\n- [Tevm cast website](https://tevm-cast.vercel.app)\n\nTevm Cast Clone is a web-based Ethereum command-line interface (CLI) emulator similar to [foundry cast](https://book.getfoundry.sh/cast/).\n\nIt's goal is:\n\n1. To provide a convenient lightweight peformant interface to do simple ethereum queries in a mobile browser\n2. Show off Tevm features such as network forking and in-browser EVM\n\n![image](https://github.com/user-attachments/assets/652e7c98-1e3f-4672-b8d6-34577f632ef6)\n\n## Features\n\n- Support for multiple Ethereum networks (Mainnet, Optimism, Base). Feel free to add new networks\n- Real-time network information display (Chain ID, Base Fee, Gas Limit, Fork Block)\n- Command history functionality\n- Execution of various Ethereum commands, including:\n  - `cast block`\n  - `cast tx`\n  - `cast call`\n  - `cast send`\n  - `cast chain-id`\n  - `cast code`\n  - `cast keccak`\n  - And more...\n- Command history and rpc urls saved in local storage\n\n## How to Use\n\n1. Select a network from the dropdown menu or enter a custom RPC URL.\n2. Enter a command in the input area (e.g., `cast bn` for block number).\n3. Click the \"Run\" button or press Enter to execute the command.\n4. View the output in the result area below.\n\n## Technical Stack\n\nThis website is built using just good old fashioned html and vanilla js\n\n- Frontend: HTML, CSS, TypeScript\n- Ethereum Interaction: Tevm library\n- Build Tool: Vite\n\n## Getting Started\n\nTo run this project locally:\n\n1. Clone the repository\n2. Install dependencies with `npm install`\n3. Start the development server with `npm run dev`\n4. Open the provided localhost URL in your browser\n\n## Files\n\n- `index.html`: The main HTML file that structures the web application's layout and includes necessary scripts and styles.\n- `main.css`: The stylesheet that defines the application's appearance, including responsive design and animations.\n- `src/main.ts`: The primary TypeScript file that initializes the application, setting up storage, nodes, HTML rendering, command runner, and event listeners.\n- `src/Nodes.ts`: Manages the creation and handling of Tevm nodes for different networks.\n- `src/Storage.ts`: Handles local storage operations, including Fork URL management and command history.\n- `src/Html.ts`: Responsible for rendering and updating HTML elements in the UI.\n- `src/EventListeners.ts`: Sets up and manages all event listeners for user interactions.\n- `src/CommandRunner.ts`: Contains the logic for executing various Ethereum commands using the Tevm Node library.\n\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request. Especially looking for contributions to add more cast commands.\n\n#### Adding a new network\n\n1. Add it to local storage https://github.com/evmts/tevm-cast/blob/main/src/Storage.ts#L1\n2. Add to html https://github.com/evmts/tevm-cast/blob/main/index.html#L37\n3. Add a tevm node https://github.com/evmts/tevm-cast/blob/main/src/Nodes.ts#L35\n\n#### Adding or updating a command\n\nCheck [src/CommandRunner.ts](./src/CommandRunner.ts]\n\n## License\n\nThis project is open source and available under the [MIT License](LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fevmts%2Ftevm-cast","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fevmts%2Ftevm-cast","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fevmts%2Ftevm-cast/lists"}