# Bal.storageAt

Returns the value a list holds for a slot at a block access index.

Resolves the same way a covered read does: the most recent write *strictly before* the index. Transaction `i` records its post-state at index `i + 1`, so reading at `i + 1` sees what preceded that transaction, not its own writes. `undefined` when the list carries no applicable write, which is when an execution would read through to the database.

## Imports

:::code-group
```ts [Named]
import { Bal } from 'ox/evm'
```

```ts [Entrypoint]
import * as Bal from 'ox/evm/Bal'
```
:::

## Examples

```ts twoslash
// @noErrors
import { Bal } from 'ox/evm'

// The value the second transaction saw.
Bal.storageAt(bal, { address, index: 2n, slot: 0n })
```

## Definition

```ts
function storageAt(
  bal: Bal,
  options: storageAt.Options,
): bigint | undefined
```

**Source:** [src/evm/Bal.ts](https://github.com/wevm/ox/blob/main/src/evm/Bal.ts#L108)

## Parameters

### bal

* **Type:** `Bal`

List to read.

### options

* **Type:** `storageAt.Options`

Account, slot, and index to resolve at.

#### options.address

* **Type:** `0x${string}`

Account holding the slot.

#### options.index

* **Type:** `bigint`

Block access index to resolve at.

#### options.slot

* **Type:** `bigint`

Slot to resolve.

## Return Type

The value, or `undefined` when none applies.

`bigint | undefined`
