windows - gatsby新命令错误 "TypeError: rd.cursorTo is not a function"

标签 windows gatsby

我使用命令 gatsby new 创建一个新站点,但出现以下错误

Cloning site template C:\Users\catal\AppData\Roaming\npm\node_modules\gatsby-cli\node_modules\yoga-layout-prebuilt\yoga-layout\build\Release\nbind.js:53
        throw ex;
        ^

TypeError: rd.cursorTo is not a function
    at Timeout._onTimeout (C:\Users\catal\AppData\Roaming\npm\node_modules\gatsby-cli\node_modules\create-gatsby\lib\index.js:5:852)
    at listOnTimeout (node:internal/timers:564:17)
    at processTimers (node:internal/timers:507:7)

Node.js v18.7.0

我使用的是 Windows 11

最佳答案

这已在 gatsbyjs/gatsby issue 35426 中报道过去年 4 月(2022 年),目前还没有最终的解决方案。

首先在本地尝试create-gatsbyfollowing its readme ,检查这是否是版本问题(尽管 node minimum version was set to 10 )。

如果可能,请在 Linux WSL2(例如 Ubuntu)VM 中尝试一下,以检查这是否与操作系统有关。

关于windows - gatsby新命令错误 "TypeError: rd.cursorTo is not a function",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/73354282/

相关文章:

GatsbyJS - 解析带或不带 ".html"后缀的页面 URL

gatsby - 如何包含自定义/本地 Gatsby 插件并在 Netlify 上构建和部署?

reactjs - 如何在 Gatsby.js 中动态渲染组件并使用代码分割?

C++ 链表仅在 GNU/Linux 而不是 Windows 中导致段错误

python - 使用biopython将字典写入文件

windows - 在 win 7 任务计划程序中顺序运行批处理文件

使用 gatsby-plugin-react-i18next 时 Gatsby 找不到客户端路由

reactjs - Gatsby 构建命令 - 内容丰富的插件无法从 .env 文件中获取 spaceId 和 accessToken

windows - 在 hyper-v 虚拟机上完成 Windows 应用程序开发

windows - Windows 的默认 PATH 系统变量?