[Solved] Google Autosuggest Address change from Javascript to Jquery


The simplest way to do this:

var input = document.getElementById('pac-input');
var output = document.getElementById('pac-output'); 

in jQuery is like this:

var input = $("#pac-input");
var output = $("#pac-output");

Or, if you prefer the verbose form:

var input = jQuery("#pac-input");
var output = jQuery("#pac-output");

And if you don’t know how to implement jQuery:

<script src="https://code.jquery.com/jquery-3.3.1.js"></script>

<script>
    //Your code here...
</script>

solved Google Autosuggest Address change from Javascript to Jquery