Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a * select to match all changes. Fixes #23. #25

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

xzyfer
Copy link
Contributor

@xzyfer xzyfer commented Jul 25, 2013

This pull request adds a * context that acts as a catch all.

var queries = [
    {
        context: 'mobile',
        match: function() {
            console.log('Mobile callback. Maybe hook up some tel: numbers?');
        },
        unmatch: function() {
            // We're leaving mobile.    
        }
    },
    {
        context: '*',
        match: function() {
            console.log('Changed breakpoint.');
        }
    }
];
// Go!
MQ.init(queries);
</script>

Now Changed breakpoint. will also be logged to the console any time any break point is matched.

@xzyfer
Copy link
Contributor Author

xzyfer commented Jul 25, 2013

Fixes #23.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant