Highlight last bar, work on all timeframe, v4 & v5 @magnumm
// This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/
// © magnumm
// revision = 1
// Works on all time frame and for version 4 & 5. You just need to comment/uncomment. Can be added in your own scripts copy/pasting just one line. 

//___________________________ VERSION 5 ___________________________
//@version=5
indicator("Highlight Last Bar", shorttitle='Highlight Last Bar')
bgcolor(barstate.isconfirmed ? na : color.new(color.yellow, transp=75))       //line to copy paste

//      //___________________________ VERSION 4 ___________________________
//      //@version=4
//      study("Highlight Last Bar", overlay=true)
//      bgcolor(barstate.isconfirmed ? na : color.new(color.yellow, transp=75))        //line to copy paste

//DON'T FORGET TO HYDRATE 