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

Add syntax highlighting for code in workshop notes #221

Closed
moosichu opened this issue Feb 5, 2018 · 1 comment

Comments

Projects
None yet
2 participants
@moosichu
Copy link
Contributor

commented Feb 5, 2018

Essentially, source markdown like this:

```java
public int fib(int n) {
  if(n <= 1) {
    return n;
  }
  int fib = 1;
  int prevFib = 1;
  for(int i=2; i<n; i++) {
    int temp = fib;
    fib+= prevFib;
    prevFib = temp;
  }
  return fib;
}
\```

Should have syntax highlighting appropriate to the language used. Currently, the result looks like this:

image

@moosichu moosichu changed the title Add syntax highlighting for code in wokrshop notes Add syntax highlighting for code in workshop notes Feb 5, 2018

@moosichu moosichu self-assigned this Feb 5, 2018

@Pinpickle

This comment has been minimized.

Copy link
Contributor

commented Feb 5, 2018

This can either be done server-side (there isn't much available in the way of Swift) or client side with some popular highlighting libraries:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.