Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-visibility-sensor

Package Overview
Dependencies
Maintainers
4
Versions
53
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-visibility-sensor - npm Package Versions

1
6

3.1.2

Diff

joshwnj
published 3.1.1 •

Changelog

Source

3.1.1

  • Removed dist file from git (as suggested in #18)
  • Added npm run build, which is also run on prepublish
  • updated the build script so browserify produces a standalone umd script
  • added example-umd to show how to use it with plain <script> tags
joshwnj
published 3.1.0 •

joshwnj
published 3.0.1 •

Changelog

Source

3.0.1

  • return the new state from .check method
joshwnj
published 3.0.0 •

Changelog

Source

3.0.0

  • upgraded to react 0.14
  • removed the package.browserify field, which is no longer needed and was causing some conflicts (#11)
joshwnj
published 2.1.0 •

Changelog

Source

2.1.0

  • new optional prop partialVisibility changes the behaviour of the sensor, so that it considers an element to be visible if it is at least partially visible (#15)
joshwnj
published 2.0.0 •

Changelog

Source

2.0.0

  • sensor DOM node is passed in as children rather than the component always rendering its own <div> (#13)
  • this also means the component also no longer accepts className or style props.

Migrating from v1.x:

If you're not setting a className or style, no change is required.

Otherwise add your own element as a child and move the className or style there. Eg:

  • before: <VisibilitySensor className='something' />
  • after: <VisibilitySensor><div className='something' /></VisibilitySensor>
joshwnj
published 1.8.0 •

joshwnj
published 1.7.0 •

joshwnj
published 1.6.1 •

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc