Socket
Socket
Sign inDemoInstall

@dotdev/reactive-google-map

Package Overview
Dependencies
Maintainers
12
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@dotdev/reactive-google-map - npm Package Compare versions

Comparing version 1.1.0 to 1.1.1

2

package.json
{
"name": "@dotdev/reactive-google-map",
"version": "1.1.0",
"version": "1.1.1",
"main": "package/index.js",

@@ -5,0 +5,0 @@ "types": "package/index.d.ts",

import usePlacesAutocomplete from "use-places-autocomplete";
export declare const useAutocomplete: (googleMapsApiKey: string, googleMapsApiVersion?: string) => ReturnType<typeof usePlacesAutocomplete>;
export declare const useAutocomplete: (options: {
googleMapsApiKey: string;
googleMapsApiVersion: string;
googleMapsOptions?: {
[key: string]: any;
/** Reference: https://developers.google.com/places/web-service/supported_types#table1 */
types?: Array<string>;
bounds?: any;
componentRestrictions?: any;
};
}) => ReturnType<typeof usePlacesAutocomplete>;

@@ -43,6 +43,6 @@ "use strict";

var utility_1 = require("../utility");
exports.useAutocomplete = function (googleMapsApiKey, googleMapsApiVersion) {
if (googleMapsApiVersion === void 0) { googleMapsApiVersion = "3.37"; }
exports.useAutocomplete = function (options) {
var placesAutocomplete = use_places_autocomplete_1.default({
initOnMount: false,
requestOptions: options.googleMapsOptions,
});

@@ -53,3 +53,3 @@ React.useEffect(function () {

switch (_a.label) {
case 0: return [4 /*yield*/, utility_1.InjectScript("https://maps.google.com/maps/api/js?v=" + googleMapsApiVersion + "&key=" + googleMapsApiKey + "&libraries=places")];
case 0: return [4 /*yield*/, utility_1.InjectScript("https://maps.google.com/maps/api/js?v=" + options.googleMapsApiVersion + "&key=" + options.googleMapsApiKey + "&libraries=places")];
case 1:

@@ -56,0 +56,0 @@ _a.sent();

Sorry, the diff of this file is not supported yet

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