@Component(
   selector: 'my-component',
   directives: const[ResizeSensor],
   template: r'''
   <div>
     some content
     <resize-sensor (resize)="$event"></resize-sensor>
   </div>
''')
   class MyComponent{
     void resize(ResizeEvent event){
       print("${event.width} ${event.height}");
     }
   }

Libraries

resize_sensor_component