Sha256: 8f9b7af9dc1e488e390ed64a4dbfa47228162d5659a6a56bab628370b30672ae

Contents?: true

Size: 347 Bytes

Versions: 55

Compression:

Stored size: 347 Bytes

Contents

require 'hamlit/concerns/error'

module Hamlit
  module Parsers
    module Doctype
      def parse_doctype(scanner)
        assert_scan!(scanner, /!!!/)

        type = nil
        if scanner.scan(/ +/) && scanner.rest?
          type = scanner.rest.strip
        end

        [:haml, :doctype, options[:format], type]
      end
    end
  end
end

Version data entries

55 entries across 55 versions & 1 rubygems

Version Path
hamlit-1.7.2 lib/hamlit/parsers/doctype.rb
hamlit-1.7.1 lib/hamlit/parsers/doctype.rb
hamlit-1.7.0 lib/hamlit/parsers/doctype.rb
hamlit-1.6.7 lib/hamlit/parsers/doctype.rb
hamlit-1.6.6 lib/hamlit/parsers/doctype.rb
hamlit-1.6.5 lib/hamlit/parsers/doctype.rb
hamlit-1.6.4 lib/hamlit/parsers/doctype.rb
hamlit-1.6.3 lib/hamlit/parsers/doctype.rb
hamlit-1.6.2 lib/hamlit/parsers/doctype.rb
hamlit-1.6.1 lib/hamlit/parsers/doctype.rb
hamlit-1.6.0 lib/hamlit/parsers/doctype.rb
hamlit-1.5.9 lib/hamlit/parsers/doctype.rb
hamlit-1.5.8 lib/hamlit/parsers/doctype.rb
hamlit-1.5.7 lib/hamlit/parsers/doctype.rb
hamlit-1.5.6 lib/hamlit/parsers/doctype.rb
hamlit-1.5.5 lib/hamlit/parsers/doctype.rb
hamlit-1.5.4 lib/hamlit/parsers/doctype.rb
hamlit-1.5.3 lib/hamlit/parsers/doctype.rb
hamlit-1.5.2 lib/hamlit/parsers/doctype.rb
hamlit-1.5.1 lib/hamlit/parsers/doctype.rb