1. enquire-js
avoid server-side rendering errors.
enquire-js
Package: enquire-js
Created by: jljsj
Last modified: Sun, 01 May 2022 08:31:48 GMT
Version: 0.2.1
License: MIT
Downloads: 38,058
Repository: https://github.com/jljsj/enquire-js

Install

npm install enquire-js
yarn add enquire-js

enquire-js

避免服务端渲染报错。

enquireScreen(cb, str);

name type default description
cb func null 回调接口, cb(bool), bool 为 true 为 mobile
str string only screen and (max-width: 767.99px) css 的场景判断

Dependencies

RELATED POST

Enhancing Vue.js Development: Harnessing the Potential of Vue-Loader

Enhancing Vue.js Development: Harnessing the Potential of Vue-Loader

Simplify Data Validation in Vue.js: A Step-by-Step Guide to Using Regex

Simplify Data Validation in Vue.js: A Step-by-Step Guide to Using Regex

Troubleshooting Made Easy: Common Issues and Solutions with vue-loader Without vue-cli

Troubleshooting Made Easy: Common Issues and Solutions with vue-loader Without vue-cli

Optimizing Webpack 4 with Vue CLI 3: Disabling the Cache-Loader

Optimizing Webpack 4 with Vue CLI 3: Disabling the Cache-Loader

Step-by-Step Guide: How to Add a Function to Your Vuex Plugin

Step-by-Step Guide: How to Add a Function to Your Vuex Plugin