首页 > 解决方案 > Javascript 和 Electron Js | window.location.pathname 错误

问题描述

function onclick () {

   window.location.pathname = "home/userıd/desktop/project folder/src/html/index.html" }

此代码有效!

function onclick () {

   window.location.pathname = "/src/html/index.html" }

它不起作用,我现在在项目文件夹中

标签: javascriptelectron

解决方案


推荐阅读