When working with jQuery, we usually do this:
$('.element').removeClass('active');
However, in A2 using BrowserDomAdapter
, the approach is a bit different:
import {BrowserDomAdapter} from 'angular2/src/platform/browser/browser_adapter'
dom = new BrowserDomAdapter();
this.dom.removeClass(this.dom.query('.mdl-layout__drawer-right'), 'active');
I'm wondering if it's possible to simplify this process by creating an extension method that would allow us to write something like this:
this.dom('.element').removeClass('active');
Do you have any thoughts on this?