Git Product home page Git Product logo

ngxautocomplace's People

Contributors

dependabot[bot] avatar vlafranca avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

ngxautocomplace's Issues

Options not working

image
image

I want that only displays places and address that are of Argentina. Are you telling me what i'm doing wrong?

Sorry for my little english :(.

Thanks

How to pass a sessionToken?

I noticed that you're using the autoCompleteService not the Widget which is way better. However, when I checked your code I did not see that you're passing a sessionToken to the getPlacePredictions method.. it will be something like that..

// assume that this is a keyup event handler
if (userInput!== "") { service.getPlacePredictions({ input: value, sessionToken: sessionToken, types: ['geocode'] }, displaySuggestions); }

Where the session token is being initialized first and then injected on keydown or keyup even handler of the input element like this
let sessionToken = new google.maps.places.AutocompleteSessionToken();

The session token gets initialized every time the user makes a selection of the address.. using sessionTokens is the right way to implement the google autocomplete service because it will reduce the bill drastically.

Note that by default every time a user type in (assuming there is no debounce), it will generate a NEW sessionToken and inject it into the getPlacePredictions()

Please, correct me if I am wrong about anything
Thank you!

Conflicts with Angular 13

I'm trying to upgrade my project to angular 13, but I'm getting the following error every time I run npm install

npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: Project.de@2.0.2
npm ERR! Found: @angular/[email protected]
npm ERR! node_modules/@angular/common
npm ERR!   @angular/common@"^13.2.2" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer @angular/common@"^10.0.0" from ngx-autocom-place@4.0.0
npm ERR! node_modules/ngx-autocom-place
npm ERR!   ngx-autocom-place@"^4.0.0" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.

As it seems, this package is not supporting angular 13

Cannot read properties of undefined (reading 'classList')

Hi, I am using the ngxAutocomPlace library for autocomplete street addresses, Here when I am using the down keyword which is trowing the Cannot read properties of undefined (reading 'classList') error ,after selecting the street address
Is there any way to avoid the issue?
error-logging.service.ts:16 TypeError: Cannot read properties of undefined (reading 'classList') at NgxAutocomPlaceDirective.keydownEvent (:4200/vendor.js:171342:80) at HTMLInputElement.<anonymous> (:4200/vendor.js:171259:22) at ZoneDelegate.invokeTask (:4200/polyfills.js:11022:31) at Object.onInvokeTask (:4200/vendor.js:56311:33) at ZoneDelegate.invokeTask (:4200/polyfills.js:11021:60) at Zone.runTask (:4200/polyfills.js:10794:47) at ZoneTask.invokeTask [as invoke] (:4200/polyfills.js:11103:34) at invokeTask (:4200/polyfills.js:12216:14) at HTMLInputElement.globalZoneAwareCallback (:4200/polyfills.js:12242:17)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.