Skip to content
On this page

getAutomine

Returns the automatic mining status of the node.

Usage

ts
import { testClient } from './client'

const isAutomining = await testClient.getAutomine() 
ts
import { createTestClient, http } from 'viem'
import { foundry } from 'viem/chains'

export const testClient = createTestClient({
  chain: foundry,
  mode: 'anvil',
  transport: http(), 
})

Returns

boolean

Whether or not the node is auto mining.

Released under the MIT License.