class Mdtoc::Node::FileNode
Public Instance Methods
headers()
click to toggle source
# File lib/mdtoc/node.rb, line 68 def headers parser = Markdown::Parser.new(@depth, @path) headers = parser.headers(File.foreach(@path)) return headers if headers[0]&.top_level?(@depth) headers.unshift(Mdtoc::Markdown::Header.new(@depth, label, @path)) end