Js报错 uncaught syntaxerror: unexpected token=?
{"name":"KADOKAWA/RPGMV","main":"www/index.html","js-flags":"--expose-gc","window":{"...
{
"name": "KADOKAWA/RPGMV",
"main": "www/index.html",
"js-flags":"--expose-gc",
"window":{
"title": "",
"toolbar": false,
"width": 816,
"height": 624,
"icon": "www/icon/icon.png"
}
} 展开
"name": "KADOKAWA/RPGMV",
"main": "www/index.html",
"js-flags":"--expose-gc",
"window":{
"title": "",
"toolbar": false,
"width": 816,
"height": 624,
"icon": "www/icon/icon.png"
}
} 展开
1个回答
展开全部
如果是在JS里写的话,需要声明成变量 不然就会报 uncaught syntaxerror: unexpected token,如果是json文件的话 应该没有问题。
<script type="text/javascript">
var obj = {
"name":"KADOKAWA/RPGMV",
"main": "www/index.html",
"js-flags":"--expose-gc",
"window":{
"title": "",
"toolbar": false,
"width": 816,
"height": 624,
"icon": "www/icon/icon.png"
}
}
</script>
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询