Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I really wished HN supported markdown personally.

Edit: I found the formatting doc for HN https://news.ycombinator.com/formatdoc

> Text after a blank line that is indented by two or more spaces is reproduced verbatim. (This is intended for code.)

So that might be the answer to putting code on here.

  function say(message: string, volume: number): void {
      //do text to speech code here
  }

but still markdown would be nicer. just do and depending on the phaser/styling it will even do code syntax coloring to increase readability.

  ```typescript
  new line with the code
  ```
(Edit again: Without the 2 spaces, HN put my markdown example all on one line)

I guess moving HN to markdown could be done. Just say all posts after X date are markdown(or add a boolean to the post in the DB saying so. Then have the editor have like a preview button(but I know HN likes to be lite on JS stuff) but the md could be generated server-side, but do the preview client side.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: