4 comments

[ 3.2 ms ] story [ 23.2 ms ] thread
The link in this show hn post, will let you browse all the ruby, markdown, and javascript changes from Bitbucket's atlassian/aui, GitHub's Microsoft/vscode and GitLab's gitlab-org/gitlab-ce repo, for the past 7 days.

The diffs browser uses Microsoft's Monaco Editor, and took practically no time to build around. I basically used the following as a starting point:

https://github.com/Microsoft/monaco-editor-samples/blob/mast...

The documentation for Monaco isn't there yet, so you'll have to crawl through the source, to figure somethings out. The two things that I needed to figure out, was how to change the font size and how to switch between side by side and inline views. The answer to both is

<diff_editor>.updateOptions({renderSideBySide: <boolean>, fontSize: <integer>})

When I get sometime, I'll do a blog post on the editor.

It turns out this new feature doesn't play nicely with how the caching system works. I know what the fix is and should get things working later this evening.
The problem has been fixed.