草庐IT

javascript - ionic 未捕获错误 : Cannot find module "." when importing a service provider

我正在尝试导入一个新的服务提供者,这是我在从我的ionic应用程序的最新分支中拉取后刚刚创建的。当我尝试导入这行代码时:import{AuthServiceProvider}from'../providers/auth-service'在app.module.ts中,我总是收到一条错误消息:UncaughtError:Cannotfindmodule"."atwebpackMissingModule(index.js:3)ate.code(index.js:3)atObject.(index.js:9)at__webpack_require__(bootstrap62d6a589782

javascript - 如何解决这个 "Uncaught TypeError: Cannot convert undefined or null to object "

我的功能是:functioncollect_que_ids(e){varval=e.val();vardata_lo=e.attr('data-lo');new_hash={};new_hash[val]=data_lo;if(e.is(':checked')){if(checked_box_hash.includes(new_hash)){checked_box_hash;}else{checked_box_hash.push(new_hash);}}else{new_hash_key=Object.keys(new_hash)[0]new_hash_value=new_hash[n

javascript - 谷歌地图未捕获类型错误 : Cannot read property 'LatLng' of undefined

我不断收到此错误“未捕获的类型错误:无法读取未定义的属性‘LatLng’”尝试创建map时在头部:................functioninit(){varlatlng=newgoogle.maps.LatLng(-43.552965,172.47315);varmyOptions={zoom:10,center:latlng,mapTypeId:google.maps.MapTypeId.ROADMAP};map=newgoogle.maps.Map(document.getElementById("map"),myOptions);}................

javascript - Fabric.js 子类化 fabric.Group - 错误 : "Cannot read property ' async' of undefined"when load from JSON

有以下问题:尝试继承fabric.Group:varCustomGroup=fabric.util.createClass(fabric.Group,{type:'customGroup',initialize:function(objects,options){options||(options={});this.callSuper('initialize',objects,options);this.set('customAttribute',options.customAttribute||'undefinedCustomAttribute');},toObject:functi

javascript - 未捕获的类型错误 : Cannot read property 'toUpperCase' of undefined react state item

我是React和Javascript的新手,我正在尝试呈现以下React组件:'usestrict';varReact=require('react');importToReadListfrom'./toreadlist.js';varToRead=React.createClass({getInitialState:function(){return{bookTitles:[]};},handleSubmit:function(e){e.preventDefault();this.state.bookTitles.push(React.findDOMNode(this.refs.bo

javascript - 未捕获的异常 : cannot call methods on tabs prior to initialization

我正在使用以下代码更改点击时的标签颜色$("ul.tabs").tabs(">.pane");但是它抛出错误uncaughtexception:cannotcallmethodsontabspriortoinitialization;attemptedtocallmethod'>.pane'谁能帮我解决这个错误是什么? 最佳答案 如异常所述,它非常简单。您必须先初始化选项卡,然后才能对其进行处理。所以初始化它们。function(){$("ul.tabs").tabs();}或者简单地使用$("ul.tabs").tabs().ta

javascript - 类型错误 : Cannot create property 'FOO' on string 'BAR'

我们应用程序中的错误(现已修复)代码触发了此错误:TypeError:Cannotcreateproperty'FOO'onstring'BAR'但是Javascript完全允许在字符串变量上设置自由属性。我刚刚在Chrome控制台中尝试过:'BAR'.FOO='hello''BAR'['FOO']='hello'而且效果很好。那么JS解释器在什么情况下会触发这个错误?原始代码是用Typescript编写的,然后用Babel转译。这是一个运行时错误。我认为这与typescript无关,因为其他人报告了类似的运行时错误,例如。here和here 最佳答案

docker login x509: cannot validate certificate for because it doesn‘t contain any IP SANs

dockerlogin私有harbor仓库时,报错,如下:Errorresponsefromdaemon:Get"https://x.x.x.x:443/v2/":x509:cannotvalidatecertificateforx.x.x.xbecauseitdoesn'tcontainanyIPSANsSAN是 subjectAltName的缩写。我们在生成证书的时候未指定这项的配置或者指定错误。参考下面两个链接去生成的证书:ConfigureHTTPSAccesstoHarbor docker-repository-certs其中有一个配置为:cat>v3.ext如果我们配置不是域名,而

javascript - 刷新 vue 应用程序给出 : Cannot GET/path

我有一个简单的webpack模板vue应用程序,假设我有一个页面http://localhost:8080/profile在我的本地页面上,我可以从任何页面转到/profile,甚至在/profile上一次,我可以刷新/重新加载页面,并且不会出现任何错误。但是我在heroku上部署了我的应用程序,即使我可以从任何页面导航到任何其他页面,但是如果我在/profile页面上,我点击刷新我得到CannotGET/statement可能是什么问题? 最佳答案 您尝试在没有后端的情况下使用路由器的历史记录模式。为了让事情正常进行,你可以使用E

javascript - 未捕获的类型错误 : Cannot read property 'document' of undefined

我有以下功能,在我测试过的几台PC上运行良好。我已经在Chrome、IE和Firefox上测试过,没有任何问题。但是,有一台特定的PC(运行Chrome)在该行抛出此错误“UncaughtTypeError:Cannotreadproperty'document'ofundefined”:win.document.write(data);难道是因为win为null?如果是这样,为什么这台特定PC会出现这种情况?是否有一些Chrome设置需要设置?方法:functionviewReport(){console.info('generatingeventreport');varfrmDat