Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
import AutoComplete from '@pluginjs/auto-complete'
import { deepMerge } from '@pluginjs/utils'
export const namespace = 'placeComplete'
export const events = deepMerge(AutoComplete.events, {
ERROR: 'error',
PLACECHANGE: 'placeChange'
})
export const classes = deepMerge(AutoComplete.classes, {
NAMESPACE: 'pj-autoComplete',
WRAP: '{namespace} pj-autoComplete-place',
ITEMQUERY: '{namespace}-item-query',
ITEMSECONDARY: '{namespace}-item-secondary'
})
export const methods = deepMerge(AutoComplete.methods, [])
export const defaults = deepMerge(AutoComplete.defaults, {
apiKey: 'AIzaSyDSx-q31rWQKqLwUahg6TrZ3R_5NT0LhFE',
minChars: 2,
searchOptions: {},
country: null, // []
types: ['geocode'],
match(data) {
return data