Using $$postDigest tip (instead of setTimeout) and find the real scroll height checkiing if sizesPropertyExist, all noted from original author (@kamilkp)