【问题标题】:Invalid Version TypeError when using nw-gyp to build the leveldown module for Windows PouchDB使用 nw-gyp 为 Windows PouchDB 构建 leveldown 模块时出现 Invalid Version TypeError
【发布时间】:2020-07-19 03:50:00
【问题描述】:

其实我已经找到了这个问题的答案,只是想记录下我的发现。

首先,这个问题并不特定于为 Windows PouchDB 构建 leveldown 模块。根据我在网上看到的,这是一个相当普遍的问题。

这与 nw-gyp 在 nw-gyp configurenw-gyp build command 之间忘记了 NW 的目标版本有关。发生这种情况时,将抛出 TyperError: Invalid Version: undefined

【问题讨论】:

    标签: windows pouchdb node-webkit leveldown


    【解决方案1】:

    解决方法其实很简单,只要在nw-gyp build的时候重新设置--target=,像这样:

    nw-gyp configure --target=0.47.0
    nw-gyp build --target=0.47.0
    

    【讨论】:

      猜你喜欢
      • 2015-11-20
      • 1970-01-01
      • 1970-01-01
      • 2015-09-27
      • 2015-01-27
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多