如何解决节点12的Vue 2错误?

时间:2019-05-13 07:07:32

标签: javascript node.js vue.js sass node-sass

节点12 node-sass 库出错。

节点返回以下错误:

Helpers.running(TestServer(port, app)) {
    val myPublicAddress = s"localhost:$port"
    val serverURL = s"ws://$myPublicAddress/ws"

    val asyncHttpClient: AsyncHttpClient = client.underlying[AsyncHttpClient]
    val webSocketClient = new WebSocketClient(asyncHttpClient)
    val queue = new ArrayBlockingQueue[String](10)
    val origin = serverURL
    val consumer: Consumer[String] = new Consumer[String] {
      override def accept(message: String): Unit = queue.put(message)
    }
    val listener = new WebSocketClient.LoggingListener(consumer)
    val completionStage = webSocketClient.call(serverURL, origin, listener)
    val f = FutureConverters.toScala(completionStage)

    // Test we can get good output from the websocket
    whenReady(f, timeout = Timeout(1.second)) { webSocket =>
      val condition: Callable[java.lang.Boolean] = new Callable[java.lang.Boolean] {
        override def call(): java.lang.Boolean = webSocket.isOpen && queue.peek() != null
      }
      await().until(condition)
      val input: String = queue.take()
      val json:JsValue = Json.parse(input)
      val symbol = (json \ "symbol").as[String]
      List(symbol) must contain oneOf("AAPL", "GOOG", "ORCL")
    }
  }
}

1 个答案:

答案 0 :(得分:0)

node-sass 已更新,可以修复该错误。现在,您可以将 node-sass 更新到与 Node 12 兼容的最新版本,并解决问题。

https://www.npmjs.com/package/node-sass/v/4.12.0

再次编码愉快!