title: How to specify max fee in @solana/web3.js Transaction
body: <p>The Solana documentation says</p>
  <blockquote>
  <p>Transactions currently include a fee field that indicates the maximum fee field a slot leader is permitted to charge to process a transaction.</p>
  </blockquote>
  <p>(source: <a href="https://docs.solana.com/implemented-proposals/transaction-fees" rel="nofollow noreferrer">https://docs.solana.com/implemented-proposals/transaction-fees</a>)</p>
  <p>But in <code>@solana/web3.js</code>, the transaction builder <code>SystemProgram.transfer</code> only takes a from, to and amount. There is a fee calculator interface and a <code>getEstimatedFee</code> method in the transfer object, but I can't find how to set the maximum.</p>