proto-kit / framework

Apache License 2.0
28 stars 10 forks source link

Network state access in module methods #15

Closed maht0rz closed 4 months ago

maht0rz commented 1 year ago

Is your feature request related to a problem? Please describe. As part of the module API, we should provide access to network state of the app chain (+ L1). This is especially useful when designing e.g. timelocked contracts, or yield farms that unlock periodically.

Describe the solution you'd like The first two pieces of information i can think of we may need, is the L1 & L2 block height / timestamp. We need to figure out what other pieces of state can we provide as part of our framework

maht0rz commented 4 months ago

We only provide L2 block height access for now via this.network in runtime methods.