Currently, if you compile typescript without the "dom" lib, there is no 'Document' type available, and so the cheerio type definitions will output an error: `error TS2304: Cannot find name 'Document'.`. This adds a blank Document interface so no error is produced.
.html() can return null when querying an element that does not exist.
Repro:
const response = await axios.default.get('https://www.google.com/')
const $ = cheerio.load(response.data)
const foo = $('.bar').html()
console.log(`foo is: ${foo}`) //foo is: null