Ember Component mixin to notify of size changes.
npm install ember-resize-awareember-resize-aware
==============================================================================



Checkout the DEMO
Simplified and updated version of ember-resize.
Provides a mixin that you can use on your components, your components will have a didResize event called on them when appropriate.
Uses ember-singularity under the hood for efficient and massively gangster event handling.
Installation
------------------------------------------------------------------------------
```
ember install ember-resize-aware
Usage
------------------------------------------------------------------------------
Just mix this sucker into a component or any ember object with the didInsertElement lifecycle hooks.
`javascript
import Component from '@ember/component';
import ResizeAware from 'ember-resize-aware/mixins/resize-aware';
export default Component.extend(ResizeAware, {
debounceRate: 400, // You can optionally set the debounce rate, the default is 200, 0 during testing.
didResize(width, height) {
// YOU GET THE WIDTH! AND THE HEIGHT! BOOM!
},
});
`
Contributing
------------------------------------------------------------------------------
* git clone cd ember-resize-aware
* yarn install
*
* yarn lint:jsyarn lint:js --fix
*
* ember test – Runs the test suite on the current Ember versionember test --server
* – Runs the test suite in "watch mode"yarn test
* – Runs ember try:each to test your addon against multiple Ember versions
* ember serve`
* Visit the dummy application at http://localhost:4200.
For more information on using ember-cli, visit https://ember-cli.com/.
License
------------------------------------------------------------------------------
This project is licensed under the MIT License.