// import { Observable } from 'rxjs/Observable';
// import 'rxjs/add/observable/fromEvent';
// import 'rxjs/add/operator/map';
// import 'rxjs/add/operator/debounceTime';
// import 'rxjs/add/operator/filter';
import { Observable, fromEvent } from 'rxjs';
import { map, debounceTime, filter } from 'rxjs/operators';

// export const RESIZE_EVENT = Observable.fromEvent(window, 'resize')
//     .map(() => {
//         return document.documentElement.clientWidth;
//     })
//     .debounceTime(200);

export const RESIZE_EVENT = fromEvent(window, 'resize')
    .pipe(map(() => {
        return document.documentElement.clientWidth;
    }))
    .pipe(debounceTime(200));
