Skip to content

Latest commit

 

History

History
92 lines (67 loc) · 2.69 KB

_snips.md

File metadata and controls

92 lines (67 loc) · 2.69 KB

quickies

rake serve:dev # serve local with drafts rake serve:prod # serve local without drafts, production only rake build && rake build:prod,dev,drafts rake push && rake push:aws3 # shove _site/ contents to my s3 bucket

terminal styled code syntax frag

A fun use case for this is styling code blocks to look like terminal windows. Simply use terminal as the language/lexer like so:

```terminal

```

And then use css to style it up. see https://mademistakes.com/til/styling-language-specific-code-blocks/

adding javascript stuff

To modify or add your own scripts include them in assets/js/_main.js and then rebuild using npm run build:js. See below for more details.

If you add additional scripts to assets/js/plugins/ and would like them concatenated with the others, be sure to update the uglify script in package.json. Same goes for scripts that you remove.

lychee notes

Now you can use the newly available tag on your blog:

{% lychee_album <album_id> %}

Replace <album_id> with the ID of the album to be displayed (Hint: look at the URL when opening an album in Lychee). To see a working example, just have a look at my personal website: Berlin - September 2013

Protip for the So Simple Theme

Place the Liquid Tag between a figure HTML tag:

{% lychee_album 1 %} And add the following JavaScript snippet to assets/js/_main.js (don’t forget to run grunt after that)

$(document).ready(function() { $('.third').magnificPopup({ delegate: 'a', type: 'image', tLoading: 'Loading image #%curr%...', mainClass: 'mfp-img-mobile', gallery: { enabled: true, navigateByImgClick: true, preload: [0,1] // Will preload 0 - before current, and 1 after the current image }, image: { tError: 'The image #%curr% could not be loaded.', titleSrc: function(item) { return item.el.attr('title') + 'by my name here'; } } }); });

include a Table of Contents (TOC)

{% include toc %}

Notices

/**

  • Default Kramdown usage (no indents!):
  • Headline for the Notice

  • Text for the notice

*/

Link Collection

Collection is _linkdump.

Suggested YAML frontmatter

2016-07-01-linkdump-$title
---
collection: linkdump
title: $TITLE-of-Item
category: linkdump
tags: {link, $tag}
uri: $URL
description: $description
---

%% content and commentary