4

I know that in Scala we have sbt plugins which allow us to execute code embedded in Markdown, plugins like tut and sbt-site. But how can we do the opposite? I would like to embed Markdown in Scala code as part of comments.

E.g.:

// number.sc file
// # Markdown code 
// some text 
1 + 1
//res0: Int = 2

And the code will than be converted to markdown.

Here is how you add numbers:
```scala
scala> 1 + 1
res0: Int = 2
```

Does someone know if something similar already exists?

tgr
  • 3,557
  • 4
  • 33
  • 63

0 Answers0