<commit_before>#enquire.js

##In a nutshell...

enquire.js is a javascript framework for programmatically handling CSS media queries.

`enquire` does not aim to be a replacement for, but rather a supplement to, CSS media queries.
Some circumstances demand more than what CSS based media queries can offer and this is where `enquire` steps in.
In a responsive design, you may want to do some complex things with your markup e.g:

 * On a mobile device, generate a new a touch friendly main menu from your current menu
 * Replace images with higher resolution variants for screens with high DPI
 * Shuffle content around on smaller screens

`enquire` makes it trivial to do all of these things and more!

##Basic Usage

###enquire.register

The main method you will be dealing with is `register`. It's basic signature is as follows:

    enquire.register(string query, object handler);

`query` is the media query which we wish to handle, and `handler` is an object containing logic to handle the supplied query.
An example of usage is as follows.

    enquire.register("screen and (max-width:1000px)", {

        match : function() {},      // required,
                                    // triggered when the media query transitions *from an unmatched to a matched state*

        unmatch : function() {},    // optional,
                                    // if supplied, triggered when the media query transitions *from a matched state to an unmatched state*.

        setup : function() {},      // optional,
                                    // if supplied, triggered once immediately upon registration of the handler<commit_msg>small change to read me<commit_after>#enquire.js

##In a nutshell...

`enquire.js` is a pure javascript framework for programmatically responding CSS media queries.

`enquire` does not aim to be a replacement for, but rather a supplement to, CSS media queries.
Some circumstances demand more than what CSS based media queries can offer and this is where `enquire` steps in.
In a responsive design, you may want to do some complex things with your markup e.g:

 * On a mobile device, generate a new a touch friendly main menu from your current menu
 * Replace images with higher resolution variants for screens with high DPI
 * Shuffle content around on smaller screens

`enquire` makes it trivial to do all of these things and more!

##Dependencies

None!

The most you will need to do is provide a [polyfill for matchMedia](https://github.com/paulirish/matchMedia.js/) support if you wish to support older browsers.

##Basic Usage

###enquire.register

The main method you will be dealing with is `register`. It's basic signature is as follows:

    enquire.register(string query, object handler);

`query` is the media query which we wish to handle, and `handler` is an object containing logic to handle the supplied query.
An example of usage is as follows.

    enquire.register("screen and (max-width:1000px)", {

        match : function() {},      // required,
                                    // triggered when the media query transitions *from an unmatched to a matched state*

        unmatch : function() {},    // optional,
                                    // if supplied, triggered when the media query transitions *from a matched state to an unmatched state*.

        setup : function() {},      // optional,
                                    // if supplied, triggered once immediately upon registration of the handler
{'fraction_non_alphanumeric': 0.06438631790744467, 'fraction_numerical': 0.0022995113538373095, 'mean_word_length': 2.8752783964365256, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 1, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3450977', 'n_tokens_mistral': 836, 'n_tokens_neox': 791, 'n_words': 457}