cpiock cpiock - 1 year ago 118
TypeScript Question

How to get current document size in angular2

How can I get the current document size of a page in angular2. With jquery I made this

$(document).width()


Thanks for help

Answer Source

the following line of code will do the work:

document.body.clientWidth;