从哪里下载 scala js 依赖项(用 %%% 指定),如何搜索它们?

Where are scala js dependencies (specified with %%%) downloaded from, and how can I search for them?

我想查看是否已为 scala JS 编译了特定的库。

我知道我可以转到 webjars 并添加它,但我如何才能知道我是否可以使用三重百分比 (%%%) 语法将其声明为依赖项,例如:

libraryDependencies += "com.github.crocodilejs" %%% "frisbee" % "1.1.3"

对于普通的 jar,我可以搜索 mvnrepository.com 和类似的 - 有什么可以搜索 scala JS 依赖项,所以我不必使用 webjars 创建自己的?

此外,scalajs 是否有类似 http://definitelytyped.org/ 的内容,以便我可以找到 JS 库的现有外观?

Scala.js jar 也发布在 Maven Central 上。您所要做的就是在名称中查找 _sjs 后缀。

我以com.chuusaishapeless为例。

对于 Scala 2.11,您会发现神器 shapeless_2.11。对于 Scala 2.11 和 Scala.js 0.6.x,您会发现工件 shapeless_sjs0.6_2.11.

除了@gzm0的回答:

您确实可以在 http://search.maven.org/ with the _sjs suffix, but an easier way might be to use the Scaladex, which is an index of all Scala libraries. There is a filter for Scala.js libraries 搜索 Scala.js 个库。

最重要的 Scala.js 库也列在 https://www.scala-js.org/libraries/

网站上

至于 DefinitelyTyped 的等价物,它实际上也是 Maven Central ,因为 Scala.js 类型外观只不过是 Scala.js 库。您可以在 https://www.scala-js.org/libraries/facades.html 找到已知的现有外观库列表,它基本上 Scala.js.

的 DefinitelyTyped