thenikso / angular-inview

AngularJS directive to check if a DOM element is in the browser viewport.
http://thenikso.github.io/angular-inview/
MIT License
480 stars 112 forks source link

What are the breaking changes in v3.0.0? #141

Closed jwhitmarsh closed 5 years ago

jwhitmarsh commented 6 years ago

Firstly, thank you for the great directive! I really appreciate the open source work you are doing, so I feel bad asking you to do more, but atm I'm struggling to work out what the breaking changes are? Comparing v2.3.1 to v3.0.0 I can see that isVisible is now checked, and that offsetObject is now calculated differently - is that why the release was a major release?

Thanks again!

alejandroiglesias commented 6 years ago

I was struggling to figure that out. In the end, I upgraded the version in my app and everything keeps working fine. I guess this library is not adhering strictly to semantic versioning.

alejandroiglesias commented 6 years ago

I was also interested in knowing if $inviewpart is also removed? I searched for it in the code and didn't found it.

jwhitmarsh commented 6 years ago

@alejandroiglesias it looks like $inviewpart was deprecated in v2. I've not used the param myself, but it looks that in v2 & v3 you can access something similar in $inviewInfo.parts.

alejandroiglesias commented 6 years ago

@jwhitmarsh thank you for your reply. I had just figured that out as well, but not mentioned in the changelog.