updating with a style function which uses rAF()