
Research
PyPI Package Disguised as Instagram Growth Tool Harvests User Credentials
A deceptive PyPI package posing as an Instagram growth tool collects user credentials and sends them to third-party bot services.
use-google-maps-script
Advanced tools
This hook can be used to load the Google Maps API script as a hook. It is heavily based on a hook provided by [@react-google-maps/api](https://github.com/JustFly1984/react-google-maps-api), but can be used when you don't need the rest of Google Maps provi
This hook can be used to load the Google Maps API script as a hook. It is heavily based on a hook provided by @react-google-maps/api, but can be used when you don't need the rest of Google Maps provided by this library.
import { ReactNode } from 'react';
import { useGoogleMapsScript, Libraries } from 'use-google-maps-script';
export function App() {
return (
<LoadScript googleMapsApiKey={process.env.NEXT_PUBLIC_GOOGLE_API_KEY}>
<SearchBox />
</LoadScript>
);
}
interface LoadScriptProps {
googleMapsApiKey: string;
children: ReactNode;
}
// Important to either declare outside component or memoize to avoid re-renders
const libraries: Libraries = ['places'];
function LoadScript({ googleMapsApiKey, children }: LoadScriptProps) {
const { isLoaded, loadError } = useLoadScript({
googleMapsApiKey,
libraries,
});
if (!isLoaded) return <div>Loading script</div>;
if (loadError) return <div>Error loading script</div>;
return children;
}
function SearchBox() {
// Could be used with https://use-places-autocomplete.netlify.app/
return <div>Search Box which relies on google maps script.</div>;
}
FAQs
This hook can be used to load the Google Maps API script as a hook. It is heavily based on a hook provided by [@react-google-maps/api](https://github.com/JustFly1984/react-google-maps-api), but can be used when you don't need the rest of Google Maps provi
The npm package use-google-maps-script receives a total of 486 weekly downloads. As such, use-google-maps-script popularity was classified as not popular.
We found that use-google-maps-script demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
A deceptive PyPI package posing as an Instagram growth tool collects user credentials and sends them to third-party bot services.
Product
Socket now supports pylock.toml, enabling secure, reproducible Python builds with advanced scanning and full alignment with PEP 751's new standard.
Security News
Research
Socket uncovered two npm packages that register hidden HTTP endpoints to delete all files on command.