How to use the modernizr.options function in modernizr

To help you get started, we’ve selected a few modernizr examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Modernizr / modernizr-neue / server / util / modernizrOptions.js View on Github external
var Modernizr = require('modernizr');

// `minify` isn't really an option, in the modernizr-the-library sense. however,
// it is treated the same as one in the modernizr-the-download-page sense.
// Rather than make this change every time we need to use the options, we have this
// neat lil convenience wrapper around it

var options = Modernizr.options().sort(function(a, b) {
      return > ? 1 : -1;
      name: 'minify',
      property: 'minify',
      group: 'minify',
      checked: true
      name: 'Add CSS classes',
      property: 'setClasses',
      checked: true

module.exports = options;
github Modernizr / modernizr-neue / server / util / docs.js View on Github external
'use strict';
var _ = require('../../frontend/js/lodash.custom.js');
var modernizr = require('modernizr');
var marked = require('marked');
var path = require('path');
var fs = require('fs');
var he = require('he');

var base = path.join(__dirname, '..', '..');

var intro = fs.readFileSync(path.join(base, 'docs', ''));

var options = modernizr.options(undefined, true);

options = _.merge(options,, function(option) {
  return _.chain(option.tags)
    .map(function(tag) {
      return _.chain(tag)

var parsedDocs = _.chain(options)
  .map(function(doc) {