在使用nuxt框架进行静态打包部署时候每次总会有一两个界面报TypeError: renderContext.renderResourceHints is not a function的错误
一开始以为是asyncData中获取的数据有问题,在各种排查后返现数据没问题,再次编译还是会有错误,最后甚至把asyncdata方法给删除掉都还是有这个错误;
翻阅nuxt文档后发现了一个参数
突然想到可能是这个问题,于是赶紧去nuxt.config.js中配置
最后再次编译完美通过,缺点就是编译时间大大边长,所以可能的话还是用不用静态部署;
- renderResourceHints renderContext 静态 TypeError functionrenderresourcehints rendercontext静态typeerror getusermedia typeerror navigator function searchlist typeerror function slice javascript typeerror uncaught function defineconfig typeerror function not typeerror classname function taro3 typeerror function track vue3 typeerror function gitbook问题 typeerror function weekday clone typeerror destroyed function error