github.com/lmittmann/w3@v0.20.0/module/eth/gas_tip_cap.go (about)

     1  package eth
     2  
     3  import (
     4  	"math/big"
     5  
     6  	"github.com/lmittmann/w3/internal/module"
     7  	"github.com/lmittmann/w3/w3types"
     8  )
     9  
    10  // GasTipCap requests the currently suggested gas tip cap after EIP-1559 to
    11  // allow a timely execution of a transaction.
    12  func GasTipCap() w3types.RPCCallerFactory[*big.Int] {
    13  	return module.NewFactory(
    14  		"eth_maxPriorityFeePerGas",
    15  		nil,
    16  		module.WithRetWrapper(module.HexBigRetWrapper),
    17  	)
    18  }