Module: Jekyll
- Defined in:
- lib/jekyll/before_after_tag.rb
Defined Under Namespace
Classes: BeforeAfterTag
Constant Summary collapse
- BEFORE_AFTER_ATTR_RE =
/(\w+)\s*=\s*(?:"([^"]*)"|'([^']*)'|(\S+))/- BEFORE_AFTER_SCRIPT_FLAG =
Dedup script: only emit the JS block once per page
:before_after_script_emitted
Class Method Summary collapse
Class Method Details
.parse_ba_attrs(markup) ⇒ Object
8 9 10 11 12 13 14 |
# File 'lib/jekyll/before_after_tag.rb', line 8 def self.parse_ba_attrs(markup) attrs = {} markup.scan(BEFORE_AFTER_ATTR_RE) do |key, double, single, | attrs[key] = double || single || end attrs end |