Nielson Rolim

Joined

2,010 Experience
20 Lessons Completed
0 Questions Solved

Activity

Hey Chris, great tutorial!
When I was implementing I noticed that the Event.initEvent() method is deprecated.
So I changed it to use the Event constructor instead:

window.initMap = function (...args) {
  const event = new Event('google-maps-callback', { bubbles: true, cancelable: true });
  event.args = args;
  document.dispatchEvent(event);
};

Screencast tutorials to help you learn Ruby on Rails, Javascript, Hotwire, Turbo, Stimulus.js, PostgreSQL, MySQL, Ubuntu, and more.

© 2024 GoRails, LLC. All rights reserved.