在第一次刷新的时候是正确的,但在第二次刷新就报错了;
VM5528:353 Uncaught (in promise) TypeError: v.w.uh is not a constructor
at c.B (eval at (maps?key=7d95f20fba04cc3f034da5442ef55b23&v=1.4.4&plugin=AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.Scale,Scale,AMap.OverView,OverView,AMap.ToolBar,ToolBar,AMap.MapType,MapType,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor,AMap.Geolocation,Geolocation,AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor&callback=amapInitComponent:3), :353:200)
at new c (eval at (maps?key=7d95f20fba04cc3f034da5442ef55b23&v=1.4.4&plugin=AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.Scale,Scale,AMap.OverView,OverView,AMap.ToolBar,ToolBar,AMap.MapType,MapType,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor,AMap.Geolocation,Geolocation,AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor&callback=amapInitComponent:3), :50:100)
at eval (eval at (maps?key=7d95f20fba04cc3f034da5442ef55b23&v=1.4.4&plugin=AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.Scale,Scale,AMap.OverView,OverView,AMap.ToolBar,ToolBar,AMap.MapType,MapType,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor,AMap.Geolocation,Geolocation,AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor&callback=amapInitComponent:3), :180:122)
at Object.dg (eval at (maps?key=7d95f20fba04cc3f034da5442ef55b23&v=1.4.4&plugin=AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.Scale,Scale,AMap.OverView,OverView,AMap.ToolBar,ToolBar,AMap.MapType,MapType,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor,AMap.Geolocation,Geolocation,AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor&callback=amapInitComponent:3), :127:261)
at eval (eval at (maps?key=7d95f20fba04cc3f034da5442ef55b23&v=1.4.4&plugin=AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.Scale,Scale,AMap.OverView,OverView,AMap.ToolBar,ToolBar,AMap.MapType,MapType,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor,AMap.Geolocation,Geolocation,AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor&callback=amapInitComponent:3), :180:78)
at c.uba (eval at (maps?key=7d95f20fba04cc3f034da5442ef55b23&v=1.4.4&plugin=AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.Scale,Scale,AMap.OverView,OverView,AMap.ToolBar,ToolBar,AMap.MapType,MapType,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor,AMap.Geolocation,Geolocation,AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor&callback=amapInitComponent:3), :181:334)
at c.B (eval at (maps?key=7d95f20fba04cc3f034da5442ef55b23&v=1.4.4&plugin=AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.Scale,Scale,AMap.OverView,OverView,AMap.ToolBar,ToolBar,AMap.MapType,MapType,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor,AMap.Geolocation,Geolocation,AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor&callback=amapInitComponent:3), :180:58)
at new c (eval at (maps?key=7d95f20fba04cc3f034da5442ef55b23&v=1.4.4&plugin=AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.Scale,Scale,AMap.OverView,OverView,AMap.ToolBar,ToolBar,AMap.MapType,MapType,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor,AMap.Geolocation,Geolocation,AMap.Autocomplete,Autocomplete,AMap.PlaceSearch,PlaceSearch,AMap.PolyEditor,PolyEditor,AMap.CircleEditor,CircleEditor&callback=amapInitComponent:3), :50:100)
at eval (index.js?fc8c:1)
解决问题:
把懒加载路由改成正常的路由(import 命名from '../路径')