npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@webmarkets/wm-google-map

v1.4.2

Published

This is a component for adding a Google Map on page with minimal styles

Downloads

99

Readme

wm-google-map

This is a component for adding a Google Map on page with minimal styles

Examples

Simple HTML Single Marker

<wm-google-map api-key="" lat="43.612255" lng="-116.292516" show-marker auto-open-marker>
  <div>
    <h3>Steven Williams, MD</h3>
    <p>8854 Emerald St Ste 140, Boise, ID 83704</p>
    <a target="_blank" rel="noreferrer noopener" href="https://www.google.com/search?hl=en-US&gl=us&q=Steven+Williams,+MD+-+Boise+General+Surgeon,+8854+Emerald+St+Ste+140,+Boise,+ID+83704&ludocid=17340090931558700075&lsig=AB86z5W6-Lrgb-vbqCCh-CT2HxDg&hl=en&gl=US#lrd=0x54ae561e751ffd4f:0xf0a460d49c87542b,1">View Reviews</a>
    <br />
    <br />
    <a target="_blank" rel="noreferrer noopener" href="https://g.page/drstevenwilliams?share">Get Directions</a>
  </div>
</wm-google-map>

Multiple Markers

<wm-google-map id="home-map" api-key="INSERTGOOGLEMAPSKEY" lat="38.4602662" lng="-123.0080742" zoom="10">
  <div>
    <h3>North Bay Eye Associates - Healdsburg</h3>
    <p>
      1310 Prentice Dr # F
      <br />
      Healdsburg, CA 95448, USA
    </p>
  </div>
</wm-google-map>
// CDN imports
import 'https://cdn.jsdelivr.net/npm/@webmarkets/[email protected]/dist/wm-google-map.es.min.js';
import { WmGoogleMapMarker } from 'https://cdn.jsdelivr.net/npm/@webmarkets/[email protected]/dist/wm-google-map.es.min.js';

// get the map programatically
let map = document.getElementById('home-map');

// add a custom marker with a URL to an image (20px x 32px recommended)
const customMarkerIcon = '/Portals/0/Images/Icons/MapPin.png';

// single marker
// map.addMarker(new WmGoogleMapMarker(38.6266173, -122.8685504));

// multiple markets
map.addMarkers([
  // Headlesburg Location
  new WmGoogleMapMarker(38.6269463, -122.8660559, customMarkerIcon),
  // Santa Rosa Location
  new WmGoogleMapMarker(38.447645, -122.7345767, customMarkerIcon),
]);