Skip to content

Latest commit

 

History

History
37 lines (25 loc) · 704 Bytes

README.md

File metadata and controls

37 lines (25 loc) · 704 Bytes

Favicon Grabber

grab all favicons attached to a webpage

Installation

pip install grabicon

Usage

from grabicon import FaviconGrabber

Example

# grab favicons using
grabber = FaviconGrabber()
favicons = grabber.grab(url)

# grab more favicons
more_favicons = grabber.grab(other_url)


favicons        # is a list of icons
icon = favicons[0]
type(icon)      # = <class 'grabicon.core.Icon'>


# Icon is an entity class defined in grabicon
icon.url        # favicon url
icon.data       # bytes of image
icon.size       # size of data in bytes
icon.type       # file types [ raster-image, raw-image, vector-image, 3d-image]
icon.extension  # icon file extensions