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

No documentation for -scastie-configuration #16220

Closed
ckipp01 opened this issue Oct 20, 2022 · 2 comments · Fixed by scala/docs.scala-lang#2810
Closed

No documentation for -scastie-configuration #16220

ckipp01 opened this issue Oct 20, 2022 · 2 comments · Fixed by scala/docs.scala-lang#2810

Comments

@ckipp01
Copy link
Member

ckipp01 commented Oct 20, 2022

Compiler version

All of them

Example

As outlined in here most users of Scaladoc are going to want to use examples of their code. However, by default the integration with scastie won't work for this since it won't recognize any of the needed dependencies, including your own code. From the response there and in the pr that added this here you see the following:

You can there specify libraryDependencies setting. It will probably be done better in future (automatically get this configuration from sbt) but for now it works like that.

However there is no further explanation on how to actually use -scastie-configuration and even looking in the code you just see it's a String setting with a description and no examples of how to actually use it.

Expectation

I'd expect for a core feature like this to be documented so that library authors can use Scaladoc with the scastie integration for their projects. Right now it's pretty unusable for snippets.

@ckipp01 ckipp01 added itype:bug stat:needs triage Every issue needs to have an "area" and "itype" label labels Oct 20, 2022
@szymon-rd szymon-rd added area:doctool area:documentation and removed stat:needs triage Every issue needs to have an "area" and "itype" label labels Oct 20, 2022
@szymon-rd szymon-rd self-assigned this Oct 20, 2022
@SethTisue
Copy link
Member

Right now it's pretty unusable for snippets

And what I'm sometimes seeing in the wild is people publishing Scaladoc that has snippets, but they don't actually run. I'm not sure the library maintainers are even noticing the play buttons.

I doubt it's a good idea for the Scastie links to be emitted to be default. As Chris wrote in the discussion,

I also then don't see a way to turn the play button off

@szymon-rd
Copy link
Contributor

Thanks for reporting! We will look into it after the current polishing of scaladoc.

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

Successfully merging a pull request may close this issue.

3 participants