Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #43: Add @javadoc directive #52

Merged
merged 3 commits into from
Nov 21, 2016
Merged

Conversation

jonas
Copy link
Contributor

@jonas jonas commented Nov 6, 2016

No description provided.

@jroper
Copy link
Member

jroper commented Nov 7, 2016

I find linking directly to the javadoc class HTML to give a terrible user experience, because then they don't have the navigation from the frames that is very often needed.

In Lagom and Play, we always link to index.html?com/example/SomeClass.html, this links to the frames version. The one problem with this approach is linking to specific methods doesn't work out of the box, to fix this you need to generate javadocs with a little javascript snippet to scroll to the right place on the frame, we do it like this in Lagom:

https://github.com/lagom/lagom/blob/master/project/Doc.scala#L60

@dwijnand
Copy link
Member

dwijnand commented Nov 7, 2016

FYI note that the frames are gone, at least in the official Scala API docs: http://www.scala-lang.org/api/current/scala/Int.html

@jroper
Copy link
Member

jroper commented Nov 7, 2016

Yep but this is for javadocs, not scaladocs.

@jonas
Copy link
Contributor Author

jonas commented Nov 7, 2016

OK, I will update the PR and rebase to add support for referenced source definitions.

@jonas jonas force-pushed the javadoc-directive branch 2 times, most recently from b5fc3d2 to 9431beb Compare November 10, 2016 06:26
@jonas jonas force-pushed the javadoc-directive branch from 9431beb to 9d7b3c4 Compare November 10, 2016 21:29
case class Url(base: URI) {
def withEndingSlash = base.getPath match {
case path if path.endsWith("/index.html") => this
case path => copy(path = path + "/")
Copy link
Contributor Author

@jonas jonas Nov 10, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The main goal here is to avoid links that will automatically redirect, yet allow to spell them out with .../index.html if so desired.

@jonas
Copy link
Contributor Author

jonas commented Nov 10, 2016

I believe I've addressed all comments.

  • javadoc links uses ? to show frames
  • Fix scaladoc links to work with Scala 2.12

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants