weprovide/magento2-module-enquire-js 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

weprovide/magento2-module-enquire-js

最新稳定版本:2.1.6.1

Composer 安装命令:

composer require weprovide/magento2-module-enquire-js

包简介

Add Enquire.js from CDN as a require.js module shim. With fallback to local version when CDN is offline.

README 文档

README

Add Enquire.js from CDN as a require.js module shim. With fallback to local version when CDN is offline.

Installation

  1. composer require weprovide/magento2-module-enquire-js
    will install the latest version. If you want a specific Enquire.js version you can use this:
    composer require weprovide/magento2-module-enquire-js:<version here>

  2. Run bin/magento setup:upgrade

  3. Run bin/magento setup:static-content:deploy

Available versions

  • 2.1.2
  • 2.1.6

Usage

For usage examples of enquire.js see the enquire.js website

require(['enquire'], function (enquire) {
  enquire.register("screen and (max-width:1000px)", {
  
      match : function() {},      // OPTIONAL
                                  // If supplied, 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*.
                                  // Also may be called when handler is unregistered (if destroy is not available)
  
      setup : function() {},      // OPTIONAL
                                  // If supplied, triggered once immediately upon registration of the handler
  
      destroy : function() {},    // OPTIONAL
                                  // If supplied, triggered when handler is unregistered. Place cleanup code here
  
      deferSetup : true           // OPTIONAL, defaults to false
                                  // If set to true, defers execution the setup function 
                                  // until the media query is first matched. still triggered just once
  });
});

统计信息

  • 总下载量: 48.66k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 2
  • Forks: 2
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2017-10-31