Debian Codegraph @

tests/output/app/gfm-test.html

raw ◀ ▶
1 Debian patch touch this file
1 <!DOCTYPE html>
2 <html lang="en">
3 <head>
4 <meta charset="utf-8" />
5 <title>gfm-test.md - Grip</title>
6 <link rel="icon" href="/__/grip/static/favicon.ico" />
7 <style>
8 /* Page tweaks */
9 .preview-page {
10 margin-top: 64px;
11 margin-bottom: 21px;
12 }
13 /* User-content tweaks */
14 .timeline-comment-wrapper > .timeline-comment:after,
15 .timeline-comment-wrapper > .timeline-comment:before {
16 content: none;
17 }
18 /* User-content overrides */
19 .discussion-timeline.wide {
20 width: 920px;
21 }
22 </style>
23 </head>
24 <body>
25 <div class="page">
26 <div id="preview-page" class="preview-page" data-autorefresh-url="/__/grip/refresh/">
27 <main id="js-repo-pjax-container">
28 <div class="clearfix new-discussion-timeline container-xl px-3 px-md-4 px-lg-5">
29 <div class="repository-content">
30 <div class="clearfix">
31 <div class="Layout Layout--flowRow-until-md Layout--sidebarPosition-end Layout--sidebarPosition-flowRow-end">
32 <div class="Layout-main">
33
34
35
36 <div id="readme" class="Box md Box--responsive">
37
38 <div class="Box-header d-flex border-bottom-0 flex-items-center flex-justify-between color-bg-default rounded-top-2">
39 <div class="d-flex flex-items-center">
40 <h2 class="Box-title">
41 gfm-test.md
42 </h2>
43 </div>
44 </div>
45
46 <div class="Box-body px-5 pb-5">
47 <article id="grip-content" class="markdown-body entry-content container-lg">
48 <h1>
49 <a id="user-content-github-flavored-markdown-test" class="anchor" href="#github-flavored-markdown-test" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>GitHub Flavored Markdown Test</h1>
50 <p>This Markdown file contains all the features of <strong>GitHub Flavored Markdown</strong> for
51 testing a renderer with.</p>
52 <p>The features are taken directly from <a href="https://daringfireball.net/projects/markdown/syntax" rel="nofollow">Daring Fireball</a>
53 and <a href="https://help.github.com/articles/github-flavored-markdown/">GitHub Flavored Markdown</a>,
54 followed by a list of one-offs.</p>
55 <h2>
56 <a id="user-content-inline-html" class="anchor" href="#inline-html" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Inline HTML</h2>
57 <table>
58 <tr>
59 <td>Foo</td>
60 </tr>
61 <tr>
62 <td>
63 Note that Markdown formatting syntax is not processed within block-level HTML tags.
64 E.g., you can’t use Markdown-style *emphasis* inside an HTML block.
65 </td>
66 </tr>
67 </table>
68 <p>Span-level HTML tags — e.g. &lt;span&gt;, &lt;cite&gt;, or &lt;del&gt; — can be used anywhere
69 in a Markdown paragraph, list item, or header. If you want, you can even use HTML tags instead
70 of Markdown formatting; e.g. if you’d prefer to use HTML &lt;a&gt; or &lt;img&gt; tags instead
71 of Markdown’s link or image syntax, go right ahead.</p>
72 <h4>
73 <a id="user-content-testing-span-cite-and-del-tags" class="anchor" href="#testing-span-cite-and-del-tags" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Testing <span>span</span>, cite, and <del>del</del> tags</h4>
74 <p>Testing <span>span</span>, cite, and <del>del</del> tags in a paragraph.</p>
75 <p>And each element in its own list item:</p>
76 <ul>
77 <li><span>This is within a span tag.</span></li>
78 <li>This is within a cite tag.</li>
79 <li><del>This is within a del tag.</del></li>
80 </ul>
81 <h2>
82 <a id="user-content-automatic-escaping-for-special-characters" class="anchor" href="#automatic-escaping-for-special-characters" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Automatic escaping for special characters</h2>
83 <ul>
84 <li>© copyright</li>
85 <li>AT&amp;T should render the same as AT&amp;T</li>
86 <li>4 &lt; 5 should render the same as 4 &lt; 5</li>
87 </ul>
88 <p>Note that GitHub Flavored Markdown has URL autolinking, which will <em>not</em>
89 convert <code>&amp;amp;</code>. So these two should yield different links:</p>
90 <ul>
91 <li><a href="http://images.google.com/images?num=30&amp;q=larry+bird" rel="nofollow">http://images.google.com/images?num=30&amp;q=larry+bird</a></li>
92 <li><a href="http://images.google.com/images?num=30&amp;amp;q=larry+bird" rel="nofollow">http://images.google.com/images?num=30&amp;amp;q=larry+bird</a></li>
93 </ul>
94 <h2>
95 <a id="user-content-paragraphs-and-line-breaks" class="anchor" href="#paragraphs-and-line-breaks" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Paragraphs and line breaks</h2>
96 <p>This is a normal paragraph.</p>
97 <p>This and the next sentence is separated by a single newline.
98 This should be on the same line.</p>
99 <p>This and the next sentence is joined by a single <code>&lt;br /&gt;</code>. <br>
100 This should be on a new line, directly below.</p>
101 <p>These two sentences are separated by two <code>&lt;br /&gt;</code> tags. <br><br>
102 This should be two lines below.</p>
103 <p>These two paragraphs are separated by two <code>&lt;br /&gt;</code> tags. <br><br></p>
104 <p>This should be three lines below.</p>
105 <h2>
106 <a id="user-content-headers" class="anchor" href="#headers" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Headers</h2>
107 <p>Here are some headers followed by <a href="https://en.wikipedia.org/wiki/Lorem_ipsum" rel="nofollow">Lorem Ipsum</a>.</p>
108 <h1>
109 <a id="user-content-this-is-an-h1-setext-style" class="anchor" href="#this-is-an-h1-setext-style" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>This is an H1 (Setext-style)</h1>
110 <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</p>
111 <h2>
112 <a id="user-content-this-is-an-h2-setext-style" class="anchor" href="#this-is-an-h2-setext-style" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>This is an H2 (Setext-style)</h2>
113 <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</p>
114 <p>The following are atx-style.</p>
115 <h1>
116 <a id="user-content-this-is-an-h1" class="anchor" href="#this-is-an-h1" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>This is an H1</h1>
117 <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</p>
118 <h2>
119 <a id="user-content-this-is-an-h2" class="anchor" href="#this-is-an-h2" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>This is an H2</h2>
120 <p>Mauris feugiat, augue vitae sollicitudin vulputate, neque arcu dapibus eros, eget semper lorem ex rhoncus nulla.</p>
121 <h3>
122 <a id="user-content-this-is-an-h3" class="anchor" href="#this-is-an-h3" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>This is an H3</h3>
123 <p>Etiam sit amet orci sit amet dui mollis molestie.</p>
124 <h4>
125 <a id="user-content-this-is-an-h4" class="anchor" href="#this-is-an-h4" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>This is an H4</h4>
126 <p>Cras et elit egestas, lacinia est eu, vestibulum enim.</p>
127 <h5>
128 <a id="user-content-this-is-an-h5" class="anchor" href="#this-is-an-h5" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>This is an H5</h5>
129 <p>Phasellus sed suscipit quam.</p>
130 <h6>
131 <a id="user-content-this-is-an-h36" class="anchor" href="#this-is-an-h36" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>This is an H√36</h6>
132 <p>Nam rutrum imperdiet purus, sit amet porttitor augue tempor quis.</p>
133 <h2>
134 <a id="user-content-blockquotes" class="anchor" href="#blockquotes" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Blockquotes</h2>
135 <p>Email-style blockquotes:</p>
136 <blockquote>
137 <p>This is a blockquote with two paragraphs. Lorem ipsum dolor sit amet,
138 consectetuer adipiscing elit. Aliquam hendrerit mi posuere lectus.
139 Vestibulum enim wisi, viverra nec, fringilla in, laoreet vitae, risus.</p>
140 <p>Donec sit amet nisl. Aliquam semper ipsum sit amet velit. Suspendisse
141 id sem consectetuer libero luctus adipiscing.</p>
142 </blockquote>
143 <p>Putting the &gt; before the first line of a hard-wrapped paragraph:</p>
144 <blockquote>
145 <p>This is a blockquote with two paragraphs. Lorem ipsum dolor sit amet,
146 consectetuer adipiscing elit. Aliquam hendrerit mi posuere lectus.
147 Vestibulum enim wisi, viverra nec, fringilla in, laoreet vitae, risus.</p>
148 </blockquote>
149 <blockquote>
150 <p>Donec sit amet nisl. Aliquam semper ipsum sit amet velit. Suspendisse
151 id sem consectetuer libero luctus adipiscing.</p>
152 </blockquote>
153 <p>Nested blockquotes (i.e. a blockquote-in-a-blockquote):</p>
154 <blockquote>
155 <p>This is the first level of quoting.</p>
156 <blockquote>
157 <p>This is nested blockquote.</p>
158 </blockquote>
159 <p>Back to the first level.</p>
160 </blockquote>
161 <p>Blockquotes containing other Markdown elements:</p>
162 <blockquote>
163 <h2>
164 <a id="user-content-this-is-a-header" class="anchor" href="#this-is-a-header" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>This is a header.</h2>
165 <ol>
166 <li>This is the first list item.</li>
167 <li>This is the second list item.</li>
168 </ol>
169 <p>Here's some example code:</p>
170 <pre><code>return shell_exec("echo $input | $markdown_script");
171 </code></pre>
172 </blockquote>
173 <h2>
174 <a id="user-content-lists" class="anchor" href="#lists" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Lists</h2>
175 <h5>
176 <a id="user-content-these-three-lists-should-be-equivalent" class="anchor" href="#these-three-lists-should-be-equivalent" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>These three lists should be equivalent</h5>
177 <p>First:</p>
178 <ul>
179 <li>Red</li>
180 <li>Green</li>
181 <li>Blue</li>
182 </ul>
183 <p>Second:</p>
184 <ul>
185 <li>Red</li>
186 <li>Green</li>
187 <li>Blue</li>
188 </ul>
189 <p>Third:</p>
190 <ul>
191 <li>Red</li>
192 <li>Green</li>
193 <li>Blue</li>
194 </ul>
195 <h4>
196 <a id="user-content-these-three-ordered-lists-should-be-equivalent" class="anchor" href="#these-three-ordered-lists-should-be-equivalent" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>These three ordered lists should be equivalent</h4>
197 <p>First:</p>
198 <ol>
199 <li>Bird</li>
200 <li>McHale</li>
201 <li>Parish</li>
202 </ol>
203 <p>Second:</p>
204 <ol>
205 <li>Bird</li>
206 <li>McHale</li>
207 <li>Parish</li>
208 </ol>
209 <p>Third:</p>
210 <ol start="3">
211 <li>Bird</li>
212 <li>McHale</li>
213 <li>Parish</li>
214 </ol>
215 <h4>
216 <a id="user-content-these-two-lists-should-be-equivalent" class="anchor" href="#these-two-lists-should-be-equivalent" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>These two lists should be equivalent</h4>
217 <p>First:</p>
218 <ul>
219 <li>Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
220 Aliquam hendrerit mi posuere lectus. Vestibulum enim wisi,
221 viverra nec, fringilla in, laoreet vitae, risus.</li>
222 <li>Donec sit amet nisl. Aliquam semper ipsum sit amet velit.
223 Suspendisse id sem consectetuer libero luctus adipiscing.</li>
224 </ul>
225 <p>Second:</p>
226 <ul>
227 <li>Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
228 Aliquam hendrerit mi posuere lectus. Vestibulum enim wisi,
229 viverra nec, fringilla in, laoreet vitae, risus.</li>
230 <li>Donec sit amet nisl. Aliquam semper ipsum sit amet velit.
231 Suspendisse id sem consectetuer libero luctus adipiscing.</li>
232 </ul>
233 <h4>
234 <a id="user-content-paragraphs-and-lists" class="anchor" href="#paragraphs-and-lists" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Paragraphs and lists</h4>
235 <ul>
236 <li>Bird</li>
237 <li>Magic</li>
238 </ul>
239 <p>Blank line separated:</p>
240 <ul>
241 <li>
242 <p>Bird</p>
243 </li>
244 <li>
245 <p>Magic</p>
246 </li>
247 </ul>
248 <h4>
249 <a id="user-content-paragraphs-within-lists" class="anchor" href="#paragraphs-within-lists" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Paragraphs within lists</h4>
250 <p>First:</p>
251 <ol>
252 <li>
253 <p>This is a list item with two paragraphs. Lorem ipsum dolor
254 sit amet, consectetuer adipiscing elit. Aliquam hendrerit
255 mi posuere lectus.</p>
256 <p>Vestibulum enim wisi, viverra nec, fringilla in, laoreet
257 vitae, risus. Donec sit amet nisl. Aliquam semper ipsum
258 sit amet velit.</p>
259 </li>
260 <li>
261 <p>Suspendisse id sem consectetuer libero luctus adipiscing.</p>
262 </li>
263 </ol>
264 <p>Second:</p>
265 <ul>
266 <li>
267 <p>This is a list item with two paragraphs.</p>
268 <p>This is the second paragraph in the list item. You're
269 only required to indent the first line. Lorem ipsum dolor
270 sit amet, consectetuer adipiscing elit.</p>
271 </li>
272 <li>
273 <p>Another item in the same list.</p>
274 </li>
275 </ul>
276 <h4>
277 <a id="user-content-blockquote-within-a-list" class="anchor" href="#blockquote-within-a-list" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Blockquote within a list</h4>
278 <ul>
279 <li>
280 <p>A list item with a blockquote:</p>
281 <blockquote>
282 <p>This is a blockquote
283 inside a list item.</p>
284 </blockquote>
285 </li>
286 </ul>
287 <h4>
288 <a id="user-content-code-within-a-list" class="anchor" href="#code-within-a-list" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Code within a list</h4>
289 <ul>
290 <li>
291 <p>A list item with a code block:</p>
292 <pre><code>&lt;code goes here&gt;
293 </code></pre>
294 </li>
295 </ul>
296 <h4>
297 <a id="user-content-accidental-lists" class="anchor" href="#accidental-lists" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Accidental lists</h4>
298 <ol start="1986">
299 <li>What a great season. (oops, I wanted a year, not a list)</li>
300 </ol>
301 <p>1986. What a great season. (<em>whew!</em> there we go)</p>
302 <h2>
303 <a id="user-content-code-blocks" class="anchor" href="#code-blocks" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Code blocks</h2>
304 <p>This is a normal paragraph:</p>
305 <pre><code>This is a code block.
306 </code></pre>
307 <p>Here is an example of AppleScript:</p>
308 <pre><code>tell application "Foo"
309 beep
310 end tell
311 </code></pre>
312 <p>Markdown will handle the hassle of encoding the ampersands and angle brackets:</p>
313 <pre><code>&lt;div class="footer"&gt;
314 &amp;copy; 2004 Foo Corporation
315 &lt;/div&gt;
316
317
318 def this_is
319 puts "some #{4-space-indent} code"
320 end
321 </code></pre>
322 <code>
323 print('Code block')
324 </code>
325 <pre>
326 print('Pre block')
327 </pre>
328 <h2>
329 <a id="user-content-horizontal-rules" class="anchor" href="#horizontal-rules" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Horizontal rules</h2>
330 <hr>
331 <hr>
332 <hr>
333 <hr>
334 <hr>
335 <h2>
336 <a id="user-content-links" class="anchor" href="#links" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Links</h2>
337 <p>Markdown supports two style of links: inline and reference.</p>
338 <p>This is <a href="http://joeyespo.com/" title="Title" rel="nofollow">an example</a> inline link.</p>
339 <p><a href="http://joeyespo.com/" rel="nofollow">This link</a> has no title attribute.</p>
340 <p>See my <a href="/about/">About</a> page for some awesome people (<em>note: broken link</em>).</p>
341 <p>This is <a href="http://joeyespo.com/" title="Optional Title Here" rel="nofollow">an example</a> reference-style link.
342 This is [an example] <a href="http://joeyespo.com/" title="Optional Title Here" rel="nofollow">id</a> reference-style link with a space separating the brackets.</p>
343 <p>These should all be equivalent:</p>
344 <ul>
345 <li><a href="http://joeyespo.com/" title="Optional Title Here" rel="nofollow">foo 1</a></li>
346 <li><a href="http://joeyespo.com/" title="Optional Title Here" rel="nofollow">foo 2</a></li>
347 <li><a href="http://joeyespo.com/" title="Optional Title Here" rel="nofollow">foo 3</a></li>
348 <li><a href="http://joeyespo.com/" title="Optional Title Here" rel="nofollow">foo 4</a></li>
349 <li><a href="http://joeyespo.com/" title="Optional Title Here" rel="nofollow">foo 5</a></li>
350 </ul>
351 <h2>
352 <a id="user-content-emphasis" class="anchor" href="#emphasis" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Emphasis</h2>
353 <ul>
354 <li><em>single asterisks</em></li>
355 <li><em>single underscores</em></li>
356 <li><strong>double asterisks</strong></li>
357 <li><strong>double underscores</strong></li>
358 <li>un<em>frigging</em>believable</li>
359 <li>*this text is surrounded by literal asterisks*</li>
360 </ul>
361 <h2>
362 <a id="user-content-code" class="anchor" href="#code" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Code</h2>
363 <ul>
364 <li>Use the <code>printf()</code> function.</li>
365 <li><code>There is a literal backtick (`) here.</code></li>
366 <li>A single backtick in a code span: <code>`</code>
367 </li>
368 <li>A backtick-delimited string in a code span: <code>`foo`</code>
369 </li>
370 <li>Please don't use any <code>&lt;blink&gt;</code> tags.</li>
371 <li>
372 <code>&amp;#8212;</code> is the decimal-encoded equivalent of <code>&amp;mdash;</code>
373 </li>
374 </ul>
375 <h2>
376 <a id="user-content-images" class="anchor" href="#images" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Images</h2>
377 <ul>
378 <li><a href="https://raw.githubusercontent.com/joeyespo/grip/master/artwork/favicon.ico" target="_blank" rel="nofollow"><img src="https://raw.githubusercontent.com/joeyespo/grip/master/artwork/favicon.ico" alt="Alt text" style="max-width:100%;"></a></li>
379 <li><a href="https://raw.githubusercontent.com/joeyespo/grip/master/artwork/favicon.ico" target="_blank" rel="nofollow"><img src="https://raw.githubusercontent.com/joeyespo/grip/master/artwork/favicon.ico" alt="Alt text" title="Optional title" style="max-width:100%;"></a></li>
380 <li><a href="https://raw.githubusercontent.com/joeyespo/grip/master/artwork/favicon.ico" target="_blank" rel="nofollow"><img src="https://raw.githubusercontent.com/joeyespo/grip/master/artwork/favicon.ico" alt="Alt text" title="Optional title attribute" style="max-width:100%;"></a></li>
381 <li>
382 <a href="https://raw.githubusercontent.com/joeyespo/grip/master/artwork/favicon.ico" target="_blank" rel="nofollow"><img src="https://raw.githubusercontent.com/joeyespo/grip/master/artwork/favicon.ico" width="32" height="32" style="max-width:100%;"></a>   ← bigger &amp; blurrier</li>
383 </ul>
384 <h2>
385 <a id="user-content-automatic-links" class="anchor" href="#automatic-links" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Automatic links</h2>
386 <ul>
387 <li><a href="http://joeyespo.com/" rel="nofollow">http://joeyespo.com/</a></li>
388 <li><a href="mailto:[email protected]">[email protected]</a></li>
389 </ul>
390 <h2>
391 <a id="user-content-backslash-escapes" class="anchor" href="#backslash-escapes" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Backslash escapes</h2>
392 <ul>
393 <li>*literal asterisks*</li>
394 <li>\ backslash</li>
395 <li>` backtick</li>
396 <li>* asterisk</li>
397 <li>_ underscore</li>
398 <li>{} curly braces</li>
399 <li>[] square brackets</li>
400 <li>() parentheses</li>
401 <li># hash mark</li>
402 <li>+ plus sign</li>
403 <li>- minus sign (hyphen)</li>
404 <li>. dot</li>
405 <li>! exclamation mark</li>
406 </ul>
407 <h2>
408 <a id="user-content-github-flavored-markdown" class="anchor" href="#github-flavored-markdown" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>GitHub Flavored Markdown</h2>
409 <p>See <a href="https://help.github.com/articles/github-flavored-markdown/">GitHub Flavored Markdown</a> for details.</p>
410 <h4>
411 <a id="user-content-multiple-underscores-in-words" class="anchor" href="#multiple-underscores-in-words" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Multiple underscores in words</h4>
412 <ul>
413 <li>wow_great_stuff</li>
414 </ul>
415 <h4>
416 <a id="user-content-url-autolinking" class="anchor" href="#url-autolinking" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>URL autolinking</h4>
417 <p><a href="http://joeyespo.com" rel="nofollow">http://joeyespo.com</a></p>
418 <h4>
419 <a id="user-content-strikethrough" class="anchor" href="#strikethrough" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Strikethrough</h4>
420 <p><del>Mistaken text.</del></p>
421 <h4>
422 <a id="user-content-fenced-code-blocks" class="anchor" href="#fenced-code-blocks" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Fenced code blocks</h4>
423 <pre><code>function test() {
424 console.log("notice the blank line before this function?");
425 }
426 </code></pre>
427 <h4>
428 <a id="user-content-syntax-highlighting" class="anchor" href="#syntax-highlighting" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Syntax highlighting</h4>
429 <div class="highlight highlight-source-python"><pre><span class="pl-en">print</span>(<span class="pl-s">'Hello!'</span>)</pre></div>
430 <div class="highlight highlight-source-js"><pre><span class="pl-smi">console</span><span class="pl-kos">.</span><span class="pl-en">log</span><span class="pl-kos">(</span><span class="pl-s">'JavaScript!'</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div>
431 <div class="highlight highlight-source-js"><pre><span class="pl-smi">console</span><span class="pl-kos">.</span><span class="pl-en">log</span><span class="pl-kos">(</span><span class="pl-s">'JavaScript (with js)!'</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div>
432 <pre lang="unmatched_language"><code>console.log('No matching language, but looks like JavaScript.');
433 </code></pre>
434 <h4>
435 <a id="user-content-tables" class="anchor" href="#tables" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Tables</h4>
436 <p>Simple:</p>
437 <table>
438 <thead>
439 <tr>
440 <th>First Header</th>
441 <th>Second Header</th>
442 </tr>
443 </thead>
444 <tbody>
445 <tr>
446 <td>Content Cell</td>
447 <td>Content Cell</td>
448 </tr>
449 <tr>
450 <td>Content Cell</td>
451 <td>Content Cell</td>
452 </tr>
453 </tbody>
454 </table>
455 <p>Pipes:</p>
456 <table>
457 <thead>
458 <tr>
459 <th>First Header</th>
460 <th>Second Header</th>
461 </tr>
462 </thead>
463 <tbody>
464 <tr>
465 <td>Content Cell</td>
466 <td>Content Cell</td>
467 </tr>
468 <tr>
469 <td>Content Cell</td>
470 <td>Content Cell</td>
471 </tr>
472 </tbody>
473 </table>
474 <p>Unmatched:</p>
475 <table>
476 <thead>
477 <tr>
478 <th>Name</th>
479 <th>Description</th>
480 </tr>
481 </thead>
482 <tbody>
483 <tr>
484 <td>Help</td>
485 <td>Display the help window.</td>
486 </tr>
487 <tr>
488 <td>Close</td>
489 <td>Closes a window</td>
490 </tr>
491 </tbody>
492 </table>
493 <p>Inner Markdown:</p>
494 <table>
495 <thead>
496 <tr>
497 <th>Name</th>
498 <th>Description</th>
499 </tr>
500 </thead>
501 <tbody>
502 <tr>
503 <td>Help</td>
504 <td>
505 <del>Display the</del> help window.</td>
506 </tr>
507 <tr>
508 <td>Close</td>
509 <td>
510 <em>Closes</em> a window</td>
511 </tr>
512 </tbody>
513 </table>
514 <p>Alignment:</p>
515 <table>
516 <thead>
517 <tr>
518 <th align="left">Left-Aligned</th>
519 <th align="center">Center Aligned</th>
520 <th align="right">Right Aligned</th>
521 </tr>
522 </thead>
523 <tbody>
524 <tr>
525 <td align="left">col 3 is</td>
526 <td align="center">some wordy text</td>
527 <td align="right">$1600</td>
528 </tr>
529 <tr>
530 <td align="left">col 2 is</td>
531 <td align="center">centered</td>
532 <td align="right">$12</td>
533 </tr>
534 <tr>
535 <td align="left">zebra stripes</td>
536 <td align="center">are neat</td>
537 <td align="right">$1</td>
538 </tr>
539 <tr>
540 <td align="left">Text right below a table.</td>
541 <td align="center"></td>
542 <td align="right"></td>
543 </tr>
544 </tbody>
545 </table>
546 <h4>
547 <a id="user-content-html" class="anchor" href="#html" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>HTML</h4>
548 <p><em>TODO: Test all allowed HTML tags.</em></p>
549 <h2>
550 <a id="user-content-writing-on-github" class="anchor" href="#writing-on-github" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Writing on GitHub</h2>
551 <p>See <a href="https://help.github.com/articles/writing-on-github/">this article</a> for details.</p>
552 <h4>
553 <a id="user-content-newlines" class="anchor" href="#newlines" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Newlines</h4>
554 <p>Roses are red
555 Violets are Blue</p>
556 <h4>
557 <a id="user-content-task-lists" class="anchor" href="#task-lists" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>Task lists</h4>
558 <ul>
559 <li class="task-list-item"><input type="checkbox" class="task-list-item-checkbox" checked="" disabled=""> @mentions, #refs, <a href="">links</a>, <strong>formatting</strong>, and <del>tags</del> are supported</li>
560 <li class="task-list-item"><input type="checkbox" class="task-list-item-checkbox" checked="" disabled=""> list syntax is required (any unordered or ordered list supported)</li>
561 <li class="task-list-item"><input type="checkbox" class="task-list-item-checkbox" checked="" disabled=""> this is a complete item</li>
562 <li class="task-list-item"><input type="checkbox" class="task-list-item-checkbox" disabled=""> this is an incomplete item</li>
563 </ul>
564 <p>Task lists can be nested to better structure your tasks:</p>
565 <ul>
566 <li class="task-list-item"><input type="checkbox" class="task-list-item-checkbox" disabled=""> a bigger project
567 <ul>
568 <li class="task-list-item"><input type="checkbox" class="task-list-item-checkbox" checked="" disabled=""> first subtask #1234</li>
569 <li class="task-list-item"><input type="checkbox" class="task-list-item-checkbox" disabled=""> follow up subtask #4321</li>
570 <li class="task-list-item"><input type="checkbox" class="task-list-item-checkbox" disabled=""> final subtask cc @mention</li>
571 </ul>
572 </li>
573 <li class="task-list-item"><input type="checkbox" class="task-list-item-checkbox" checked="" disabled=""> a separate task</li>
574 </ul>
575 <h4>
576 <a id="user-content-references" class="anchor" href="#references" aria-hidden="true"><span aria-hidden="true" class="octicon octicon-link"></span></a>References</h4>
577 <ul>
578 <li>SHA: dbcd7a410ee7489acf92f40641a135fbcf52a768</li>
579 <li>User@SHA: joeyespo@dbcd7a410ee7489acf92f40641a135fbcf52a768</li>
580 <li>User/Repository@SHA: joeyespo/grip@dbcd7a410ee7489acf92f40641a135fbcf52a768</li>
581 <li>#Num: #135</li>
582 <li>GH-Num: GH-135</li>
583 <li>User#Num: joeyespo#135</li>
584 <li>User/Repository#Num: joeyespo/grip#135</li>
585 </ul>
586
587 </article>
588 </div>
589 </div>
590
591
592
593 </div>
594 </div>
595 </div>
596 </div>
597 </div>
598 </main>
599 </div>
600 </div><script>
601 function showCanonicalImages() {
602 var images = document.getElementsByTagName('img');
603 if (!images) {
604 return;
605 }
606 for (var index = 0; index < images.length; index++) {
607 var image = images[index];
608 if (image.getAttribute('data-canonical-src') && image.src !== image.getAttribute('data-canonical-src')) {
609 image.src = image.getAttribute('data-canonical-src');
610 }
611 }
612 }
613
614 function scrollToHash() {
615 if (location.hash && !document.querySelector(':target')) {
616 var element = document.getElementById('user-content-' + location.hash.slice(1));
617 if (element) {
618 element.scrollIntoView();
619 }
620 }
621 }
622
623 function autorefreshContent(eventSourceUrl) {
624 var initialTitle = document.title;
625 var contentElement = document.getElementById('grip-content');
626 var source = new EventSource(eventSourceUrl);
627 var isRendering = false;
628
629 source.onmessage = function(ev) {
630 var msg = JSON.parse(ev.data);
631 if (msg.updating) {
632 isRendering = true;
633 document.title = '(Rendering) ' + document.title;
634 } else {
635 isRendering = false;
636 document.title = initialTitle;
637 contentElement.innerHTML = msg.content;
638 showCanonicalImages();
639 }
640 }
641
642 source.onerror = function(e) {
643 if (e.readyState === EventSource.CLOSED && isRendering) {
644 isRendering = false;
645 document.title = initialTitle;
646 }
647 }
648 }
649
650 window.onhashchange = function() {
651 scrollToHash();
652 }
653
654 window.onload = function() {
655 scrollToHash();
656 }
657
658 showCanonicalImages();
659
660 var autorefreshUrl = document.getElementById('preview-page').getAttribute('data-autorefresh-url');
661 if (autorefreshUrl) {
662 autorefreshContent(autorefreshUrl);
663 }
664 </script>
665 </body>
666 </html>