Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
ember-element-resize-detector
Advanced tools
ember install ember-element-resize-detector
This addon provides a resize-detector
service and a {{resize-detector}}
component.
This component allows you to specify what element should be monitored for change and what action should be triggered.
{{resize-detector '#my-container' on-resize=(action 'resize')}}
<div id="my-container"></div>
jQuery CSS selector for an element that should be watched.
Action to be triggered when resized. The action handler will receive a hash with width
and height
as well as the element that changed sizes.
The service allows you to create components that monitor sizes of other DOM elements. To use the service in you need to inject into the component and add a listener.
To see a complete implementation, look at the {{resize-detector}}
component's code.
The service provides two methods.
Will add a listener that'll trigger the callback when the element matching the selector changes in size.
Selector is jQuery selector that'll match the element. The detector will only watch the first matched element. I would recommend creating callbacks using Ember.run.bind
to ensure that
the runloop is started when the callback is called.
Will remove the listener from element matching selector for given callback.
If it is a bug please open an issue on GitHub.
To use this addon as a dependency of another addon, you must specify this addon as a peerDependency of your addon. This will cause the host app that's installing your addon to also install this addon in the root node_modules. For more formation, read comment in ember-tether library.
This addon uses wnr/element-resize-detector library. Lucas Wiener thank you for doing the hard to work make this performant.
FAQs
The default blueprint for ember-cli addons.
The npm package ember-element-resize-detector receives a total of 1,362 weekly downloads. As such, ember-element-resize-detector popularity was classified as popular.
We found that ember-element-resize-detector demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.