safeRAF

a helper function on top of requestFrame