Provides a service liquid-fire-events that you can use to subscribe to the
following events from Liquid Fire: transitionBegan and transitionAnimated.
Example usage:
export default Ember.Component.extend({
liquidFireEvents: Ember.inject.service(),
didInsertElement() {
this.get('liquidFireEvents')
.on('transitionBegan', () => {
this.set('animating', true);
}).on('transitionAnimated'), (newView) => {
this.set('animating', false);
});
}
});Note: these are global events, fired every time a Liquid Fire transition occurs anywhere within the rendered DOM.
Additionally, this addon provides a component delayed-render which
wraps a block of markup and only renders it after a transition has finished.
This is useful eg. to avoid rendering while animating, a common cause of jank
especially in mobile browsers.
Example usage:
ember install liquid-fire-events
git clonethis repositorynpm installbower install
ember server- Visit your app at http://localhost:4200.
npm test(Runsember try:testallto test your addon against multiple Ember versions)ember testember test --server
ember build
For more information on using ember-cli, visit http://www.ember-cli.com/.