Call page.end after writing.