Published 2020-10-03.
Last modified 2025-01-14.
Time to read: 2 minutes.
jekyll_plugins collection.
This Jekyll plugin formats citations and quotes in a Jekyll website.
Installation
Add the following highlighted line to your Jekyll project's Gemfile,
within the jekyll_plugins group:
group :jekyll_plugins do gem 'jekyll_quote' end
And then execute:
$ bundle install
Syntax
{% quote OPTIONS %}
Content of quote goes here.
{% endquote %}
The default preposition is 'From'.
OPTIONS are:
-
break– Put the citation on a separate line. Ignored ifcitewas not specified. -
by– Preface the citation with the preposition 'By'. Ignored ifcitewas not specified. cite– Citation textclass– Add specified CSS classes to outerdivid– HTML id attribute for the enclosingdiv-
noprep– Do not preface the citation with a preposition. Ignored ifcitewas not specified. style– Add specified CSS styles to outer div-
url– URL for the citation. Ignored ifcitewas not specified.
Usage Examples
-
HTML or markdown
{% quote cite="Blaise Pascal, in Lettres provinciales" url="https://en.wikipedia.org/wiki/Lettres_provinciales" %} I have only made this letter longer because I have not had the time to make it shorter. {% endquote %}
Renders as:
I have only made this letter longer because I have not had the time to make it shorter. – From Blaise Pascal, in Lettres provinciales -
HTML or markdown
{% quote break cite="Blaise Pascal" url="https://en.wikipedia.org/wiki/Lettres_provinciales" %} <code>break</code>, <code>cite</code> and <code>url</code> were provided. {% endquote %}
Renders as:
break,citeandurlwere provided.– From Blaise Pascal -
HTML or markdown
{% quote break by cite="Blaise Pascal" url="https://en.wikipedia.org/wiki/Lettres_provinciales" %} <code>by</code>, <code>break</code>, <code>cite</code> and <code>url</code> were provided. {% endquote %}
Renders as:
by,break,citeandurlwere provided.– By Blaise Pascal -
HTML or markdown
{% quote break noprep cite="Blaise Pascal" url="https://en.wikipedia.org/wiki/Lettres_provinciales" %} <code>noprep</code>, <code>break</code>, <code>cite</code> and <code>url</code> were provided. {% endquote %}
Renders as:
noprep,break,citeandurlwere provided. -
HTML or markdown
{% quote noprep cite="Blaise Pascal" url="https://en.wikipedia.org/wiki/Lettres_provinciales" %} <code>noprep</code>, <code>cite</code> and <code>url</code> were provided. {% endquote %}
Renders as:
Without Url
-
HTML or markdown
{% quote cite="Blaise Pascal" %} Only a <code>cite</code> was specified. {% endquote %}
Renders as:
Only a citewas specified. – From Blaise Pascal
{% quote by cite="Blaise Pascal" %}
<code>By</code> and <code>cite</code> were specified.
{% endquote %}
Renders as:
By and cite were specified.
– By Blaise Pascal