Introduce the ability to edit chain data. #1851
Unanswered
neuodev
asked this question in
Idea / Feature Request
Replies: 1 comment
-
Chains are just objects. You should be able to manipulate them however you want in user land. Unless this is a common use-case, it not worth designing an API around it yet. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
At the moment, you only have two options:
viem/chains
.defineChain
.There are some use cases in which it makes sense to
mutate
the existing chain configs. For example, adding a new default RPC or a new explorer, updating the name of the chain, etc.Imagine that the provided RPC in the default chain config doesn't work any more, in this case, the only other option will be to define your full chain config.
I would like to introduce a new third option: mutate existing chain data.
I can imagine it working like this:
Any other implementation will be welcomed. I can implement this feature myself!
Beta Was this translation helpful? Give feedback.
All reactions