Skip to content

Commit

Permalink
fix jquery deprecation warning inside iframe
Browse files Browse the repository at this point in the history
  • Loading branch information
Gaurav0 committed Mar 2, 2020
1 parent de5dd10 commit ef68c94
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions blueprints/mouse_events_initializer.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
import jQuery from 'jquery';
/* eslint-disable ember/no-global-jquery */

import config from '../config/environment';

export default {
name: 'mouse-events',
initialize: function() {
jQuery(window).on("mousemove", function(event) {
$(window).on("mousemove", function(event) {
window.parent.postMessage({
mousemove: {
pageX: event.pageX,
pageY: event.pageY
}
}, config.TWIDDLE_ORIGIN);
});
jQuery(window).on("mouseup", function(event) {
$(window).on("mouseup", function(event) {
window.parent.postMessage({
mouseup: {
pageX: event.pageX,
Expand Down

0 comments on commit ef68c94

Please sign in to comment.