R syntax highlighting on Discourse

Is there a way to do r syntax highlighting with code blocks here?

4 Likes

Maybe there is something admins could do to enable R?

2 Likes

@martinmodrak do you know how to turn these things on or off?

So this is actually already configured, however there was a bug in how it was setup for R. I just fixed that

so starting ```stan gives

transformed parameters {
  vector[5] = call();
}

We now also have ```r

a  <- function(x) {  
  return(x + 1)
}

And python (```python) has always worked.

def my_function():
  print("Hello from a function") 
5 Likes

Amazing! Thanks!