Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Scala Docs in IntelliJ

How do I access Scala docs in IntelliJ? The other answers in SO are for earlier versions. I added the scala doc jar file, but still I am unable to link scala docs with IntelliJ.enter image description here

I do get the Quick Documentation as shown: enter image description here

But I want the complete doc as here

Also, clicking on the Actor hyperlink shows me this code, but not the API doc. There are the download and Attach sources link and I dont understand what they are. enter image description here

like image 615
codingsplash Avatar asked Jan 03 '17 05:01

codingsplash


People also ask

Can you write Scala in IntelliJ?

To start working with Scala in IntelliJ IDEA you need to download and enable the Scala plugin. If you run IntelliJ IDEA for the first time, you can install the Scala plugin when IntelliJ IDEA suggests downloading featured plugins. Otherwise, you can use the Settings | Plugins page for the installation.

How do I add Scala support to IntelliJ?

Open IntelliJ IDEA, go to File Menu --> Plugins --> [ Or directly press Ctrl+Alt+S ] Click on "Browse repositories" button and enter "Scala". Select Scala plugin to install it.


1 Answers

What do you mean by "link scala docs"? You can get documentation for a symbol (class, method) by pressing Ctrl-Q (or menu View > Quick Documentation). This seems to work at least with sbt based projects, even if in Project Structure > Project Settings > Libraries > SBT: org.scala-lang:scala-library:2.12.1:jar there is only classes and sources, and no explicit pointer to javadocs (I guess IntelliJ might extract them directly from the sources).

enter image description here

Also, are you using the latest version of IntelliIJ and the Scala plugin? For me, if I create a global Scala SDK (which you don't actually need when you use sbt build projects), IntelliJ by default does not have javadocs checked, but sources, and again I think it will extract the documentation from the sources. This is how it looks here with IntelliJ IDEA 2016.3.1 and Scala plugin 2016.3.5:

enter image description here

like image 144
0__ Avatar answered Oct 18 '22 19:10

0__