How to get source code of page?

WebDriver driver = DriverFactory.getWebDriver()
def html = driver.getPageSource()
println(html)

But see this also: