📅 You're Invited: Meet the Socket team at RSAC (April 28 – May 1).RSVP
Socket
Sign inDemoInstall
Socket

tw-angular-google-places-autocomplete

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tw-angular-google-places-autocomplete

angular-google-places-autocomplete ================

0.2.14
latest
Source
npm
Version published
Weekly downloads
9
125%
Maintainers
1
Weekly downloads
 
Created
Source

angular-google-places-autocomplete

Angular directive for the Google Places Autocomplete component.

Installation

Install via bower: bower install angular-google-places-autocomplete

Or if you're old skool, copy src/autocomplete.js into your project.

Then add the script to your page (be sure to include the Google Places API as well):

<script src="https://maps.googleapis.com/maps/api/js?libraries=places"></script>
<script src="/bower_components/angular-google-places-autocomplete/src/autocomplete.js"></script>

You'll probably also want the styles:

<link rel="stylesheet" href="/bower_components/angular-google-places-autocomplete/src/autocomplete.css">

Usage

First add the dependency to your app:

angular.module('myApp', ['google.places']);

Then you can use the directive on text inputs like so:

<input type="text" g-places-autocomplete ng-model="myScopeVar" />

The directive also supports the following optional attributes:

  • forceSelection — forces the user to select from the dropdown. Defaults to false.
  • options — See google.maps.places.AutocompleteRequest object specification.

Examples

Issues or feature requests

Create a ticket here

Contributing

Issue a pull request including any relevant testing and updated any documentation if required.

FAQs

Package last updated on 24 Dec 2016

Did you know?

Socket

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.

Install

Related posts