InvalidValueError: not an instance of HTMLInputElement

前端 未结 8 1660
刺人心
刺人心 2020-12-09 08:23

FYI, I\'m not a JavaScript Ninja but felt like I\'ll become one when I did a lot of things based on Google Maps recently.

I implemented a map. User can search for go

8条回答
  •  臣服心动
    2020-12-09 09:01

    This is an issue of DOM. Your javascript loads before loading your html document.

    Make sure your html elements load first and then only load javascript.

    Like

    and then

    Your javascript code

提交回复
热议问题