module Kramdown::Options

def self.str_to_sym(data)

- An empty value or a value equal to "nil" results in +nil+.
- A leading colon is stripped from the string.

following provisions:
Converts the given String +data+ into a Symbol or +nil+ with the
def self.str_to_sym(data)
  data = data.strip
  data = data[1..-1] if data[0] == ':'
  (data.empty? || data == 'nil' ? nil : data.to_sym)
end