question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

No `setFields` config option

See original GitHub issue

There is no clear exposed API for setting the fields on the Autocomplete instance. This is not ideal, as someone using this library might not realize google includes all fields by default, charging you for the additional apis that those fields may involve. To put it into context, someone who definitely isn’t me used this in production and was charged $1400 for places API (expected) and an additional $700 for “atmosphere” and “contacts” data (unexpected)

For such an important configuration, there should be a first-class configuration option to handle this.

Currently, I have a ref on the input and am able to add my own config this way:

   componentDidMount() {
    this.inputRef.current.autocomplete.setFields(['formatted_address', etc.])
  }

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:4
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
heyitstowlercommented, Oct 23, 2018

Yeah, no problem! I’ll submit a PR tomorrow or Tuesday

0reactions
mlucoolcommented, Dec 29, 2018

@ctowler157 Were you ever able to add this?

Read more comments on GitHub >

github_iconTop Results From Across the Web

how to use setFields in multiregionsolver - Forums - CFD Online
I use the following command,but the converted data can not work in tecplot. Code: foamToTecplot360 -region fluid foamToTecplot360 -region solid.
Read more >
Solved: Can't set fields Unique - ServiceNow Community
Solved: Hi Everyone, I Just can't set fields to Unique no matter what ... fields are still getting duplicated even with the option...
Read more >
How to initialize non-uniform fields in OpenFOAM - YouTube
In this video I show you how you can utilize the new optimized version of setFields for the initialization of non -uniform fields....
Read more >
Do not set Fields "Touched" that just get Activated ... - GitHub
Suggested Solution. In handleBlur do not set the field to touched in case the field is empty. Maybe add a configuration option to ......
Read more >
Ant Design. How to set form field error message dynamically?
the syntax is updated in v4. new syntax is: setFields. | Set fields status | (fields: FieldData[]) => void. example : form.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found