docs/vendor/mixitup/mixitup.js
function() {
            var self        = this,
                instruction = self.parseFilterArgs(arguments);

            return self.multimix({
                filter: instruction.command
            }, instruction.animate, instruction.callback);
        }
function() {
            var self        = this,
                instruction = self.parseFilterArgs(arguments);

            return self.multimix({
                filter: instruction.command
            }, instruction.animate, instruction.callback);
        }
function ( ) { var self = this , instruction = self . parseFilterArgs ( arguments ) ; return self . multimix ( { filter : instruction . command } , instruction . animate , instruction . callback ) ; }
Filters all targets in the container by a provided selector string, or the values `'all'`
or `'none'`. Only targets matching the selector will be shown.

@example

.filter(selector [, animate] [, callback])

@example <caption>Example 1: Filtering targets by a class selector</caption>

mixer.filter('.category-a')
.then(function(state) {
console.log(state.totalShow === containerEl.querySelectorAll('.category-a').length); // true
});

@example <caption>Example 2: Filtering targets by an attribute selector</caption>

mixer.filter('[data-category~="a"]')
.then(function(state) {
console.log(state.totalShow === containerEl.querySelectorAll('[data-category~="a"]').length); // true
});

@example <caption>Example 3: Filtering targets by a compound selector</caption>

// Show only those targets with the classes 'category-a' AND 'category-b'

mixer.filter('.category-a.category-c')
.then(function(state) {
console.log(state.totalShow === containerEl.querySelectorAll('.category-a.category-c').length); // true
});

@example <caption>Example 4: Filtering via an element collection</caption>

var collection = Array.from(container.querySelectorAll('.mix'));

console.log(collection.length); // 34

// Filter the collection manually using Array.prototype.filter

var filtered = collection.filter(function(target) {
return parseInt(target.getAttribute('data-price')) > 10;
});

console.log(filtered.length); // 22

// Pass the filtered collection to MixItUp

mixer.filter(filtered)
.then(function(state) {
console.log(state.activeFilter.collection.length === 22); // true
});

@public
@instance
@since       2.0.0
@param       {(string|HTMLElement|Array.<HTMLElement>)} selector
Any valid CSS selector (i.e. `'.category-a'`), or the values `'all'` or `'none'`. The filter method also accepts a reference to single target element or a collection of target elements to show.
@param       {boolean}   [animate=true]
An optional boolean dictating whether the operation should animate, or occur syncronously with no animation. `true` by default.
@param       {function}  [callback=null]
An optional callback function to be invoked after the operation has completed.
@return      {Promise.<mixitup.State>}
A promise resolving with the current state object.
Filters all targets in the container by a provided selector string or the values all or none . Only targets matching the selector will be shown .