Skip to content

wmzy/storage-layout-fetcher

Repository files navigation

Storage Layout Fetcher

npm version Build Status Coverage Status

Table of Contents

Description

Storage Layout Fetcher is a lightweight library for fetching storage layouts of verified contracts.

Installation

To install Storage Layout Fetcher, use npm or pnpm:

npm install storage-layout-fetcher

or

pnpm add storage-layout-fetcher

Usage

Here is a basic example of how to use Fetch Fun:

import fetchStorageLayout from 'storage-layout-fetcher';

const storageLayout = await fetchStorageLayout('0x06012c8cf97bead5deae237070f9587f8e7a266d', 'mainnet');

How it works

  1. fetch source code from explorers.

  2. ensure the solc_version is greater than 0.6.8

    if not, modify the solc_version to 0.6.8 and try to modify the contract to be compatible with 0.6.8

  3. compile and return the storage layout.

Contributing

We welcome contributions to Storage Layout Fetcher! If you have any ideas, suggestions, or bug reports, please open an issue on our GitHub repository.

To contribute code, please follow these steps:

  1. Fork the repository.
  2. Create a new branch (git checkout -b feature-branch).
  3. Make your changes and commit them (git commit -m 'Add new feature').
  4. Push to the branch (git push origin feature-branch).
  5. Open a pull request.

Please ensure your code adheres to our coding standards and includes appropriate tests.

License

This project is licensed under the MIT License.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors