in fragment.go [40:58]
func (h *HtmlFragment) Fragments() (map[string]*Fragment, error) {
h.RLock()
defer h.RUnlock()
scripts := h.doc.Find("head script[type=fragment]")
fragments := h.doc.Find("fragment").AddSelection(scripts)
ff := make(map[string]*Fragment)
fragments.Each(func(i int, s *goquery.Selection) {
f := FromSelection(s)
if !f.deferred {
ff[f.ID()] = f
}
})
return ff, nil
}