Back-ticks
for inline code.
`Back-ticks` for inline code.
Three back-ticks ```
or tildes ~~~
at the top and bottom.
``` if (!selector) { selector = $this.attr('href') selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') } if ($this.parent('li').hasClass('active')) return var previous = $ul.find('active')[0] var e = $.Event('show.active', { relatedTarget: previous }) ```
if (!selector) {
selector = $this.attr('href')
selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '')
}
if ($this.parent('li').hasClass('active')) return
var previous = $ul.find('active')[0]
var e = $.Event('show.active', {
relatedTarget: previous
})
Make code blocks more festive by adding highlights. Type the language name after the top set of back-ticks or tildes.
See a complete list of supported languages on Pygment's website.
~~~css .img-retina(@file-1x; @file-2x; @width-1x; @height-1x) { background-image: url("@{file-1x}"); } @media only screen and (-webkit-min-device-pixel-ratio: 2), only screen and ( min--moz-device-pixel-ratio: 2), only screen and ( -o-min-device-pixel-ratio: 2/1), only screen and ( min-device-pixel-ratio: 2), only screen and ( min-resolution: 192dpi), only screen and ( min-resolution: 2dppx) ~~~
.img-retina(@file-1x; @file-2x; @width-1x; @height-1x) {
background-image: url("@{file-1x}");
}
@media only screen and (-webkit-min-device-pixel-ratio: 2),
only screen and ( min--moz-device-pixel-ratio: 2),
only screen and ( -o-min-device-pixel-ratio: 2/1),
only screen and ( min-device-pixel-ratio: 2),
only screen and ( min-resolution: 192dpi),
only screen and ( min-resolution: 2dppx)
```python from datetime import datetime class TokensV2(object): def __init__(self, app): self.app = app def on_post(self, req, resp): body = req.stream.read().decode() index_url = self.app.get_dispatcher('identity').get_endpoint_url(req, 'v2_auth_index') v2_url = self.app.get_dispatcher('compute').get_endpoint_url(req, 'v2_index') ```
from datetime import datetime
class TokensV2(object):
def __init__(self, app):
self.app = app
def on_post(self, req, resp):
body = req.stream.read().decode()
index_url = self.app.get_dispatcher('identity').get_endpoint_url(req, 'v2_auth_index')
v2_url = self.app.get_dispatcher('compute').get_endpoint_url(req, 'v2_index')