Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-google-autocomplete

Package Overview
Dependencies
Maintainers
1
Versions
49
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-google-autocomplete - npm Package Compare versions

Comparing version 2.7.2 to 2.7.3

10

lib/utils.js

@@ -30,9 +30,9 @@ "use strict";

var scriptUrl = new URL(googleMapsScriptUrl);
scriptUrl.searchParams.set("callback", "__REACT_GOOGLE_AUTOCOMPLETE_CALLBACK__");
var el = document.createElement("script");
el.src = googleMapsScriptUrl;
document.body.appendChild(el);
el.src = scriptUrl.toString();
return new Promise(function (resolve) {
el.addEventListener("load", function () {
return resolve();
});
window.__REACT_GOOGLE_AUTOCOMPLETE_CALLBACK__ = resolve;
document.body.appendChild(el);
});

@@ -39,0 +39,0 @@ };

{
"name": "react-google-autocomplete",
"version": "2.7.2",
"version": "2.7.3",
"description": "React component for google autocomplete.",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -27,10 +27,14 @@ export const isBrowser = typeof window !== "undefined" && window.document;

let scriptUrl = new URL(googleMapsScriptUrl);
scriptUrl.searchParams.set(
"callback",
"__REACT_GOOGLE_AUTOCOMPLETE_CALLBACK__"
);
const el = document.createElement("script");
el.src = googleMapsScriptUrl;
el.src = scriptUrl.toString();
document.body.appendChild(el);
return new Promise((resolve) => {
el.addEventListener("load", () => resolve());
window.__REACT_GOOGLE_AUTOCOMPLETE_CALLBACK__ = resolve;
document.body.appendChild(el);
});
};
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc