Introduction to mongoose modified at time automatic recording plug-in

Mongoose modified at is a mongoose plug-in that automatically updates the field change time and records it to the database, similar to the timestamps function of mongoose. Usage scenarios Let's consider a scenario. We have an article release and display requirement. The data model is as follows. const schema = new mongoose.Schema({ // Article ...

Posted by amazinggrace1983 on Mon, 28 Oct 2019 03:04:52 +0100

The method of building gitee hexo blog

The method of building gitee warehouse + hexo static blog on windows Build gitee blog Environmental requirements system Software windows Git, node.js (cnpm is recommended) Install Nodejs windows download binary package link: https://nodejs.org/dist/v10.16.3/node-v10.16.3-win-x64.zip Manually unzip it to the directory you want to store. H ...

Posted by peyups on Fri, 25 Oct 2019 13:19:47 +0200

Instructions for Vue.js

Instructions for Vue.js The instructions of Vue.js start with v -, which act on HTML elements. The instructions provide some special features. When binding the instructions to the elements, the instructions will add some special behaviors to the binding target elements. We can regard the instructions ...

Posted by phileplanet on Fri, 25 Oct 2019 12:16:09 +0200

Knowledge Points in Peacetime Work and Study

13. Use of meta tags <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> <!-- Use the latest browser by default --> <meta http-equiv="Cache-Control" content="no-siteapp"> <!-- Not being webpage(accelerate)transcoding --> <meta name="robots" content="index,follow"> <!-- Search Engine Grab --> <me ...

Posted by webrajesh on Fri, 11 Oct 2019 17:26:44 +0200

WeChat Mini program

VSCode Node.js HbuilderX Installation of front-end development environment image.png npm install -g cnpm --registry=https://registry.npm.taobao.org cnpm install -g less image.png HBuilderX is the best front-end development tool in China. We use it to develop Electron project and small program project. image.png ...

Posted by LTJason on Thu, 10 Oct 2019 04:22:51 +0200

vue uses clipboard to copy content twice before successful problem modification

In the project, we need to realize the function of replication, using clipboard, clipboard.js official website address: http://www.clipboardjs.cn/ Use steps: I. Installation Module npm install clipboard --save or cnpm install clipboard --save Two, use At first, I wrote in the method to instantia ...

Posted by tnkannan on Sun, 06 Oct 2019 01:06:58 +0200

Using Gulp on Windows

Take Windows 10 as an example premise NodeJS has been installed and configured. install cmd enters the Windows command line window, enters the test directory, C: Develop gulptest, and executes under the test directory if no creation is required. C:\Develop>mkdir gulptest C:\Develop>cd gulp ...

Posted by blackhawk08 on Sat, 05 Oct 2019 16:37:35 +0200

How to introduce BootStrap in Vue?

How does Vue introduce BootStrap? Installation of Node.JS Because Vue relies on Node.JS, install Node.JS first (at least version 8.9) Installation of VueCli Tools Command window input NPM install-g@vue/cli to install the latest version of VueCli tool Vue-V Viewable Vue Version NPM install-g@vue/cli-init retrievable old version III. Creati ...

Posted by Gamerz on Fri, 04 Oct 2019 03:44:50 +0200

Vue project code initialization

Perfecting meta tags <meta name="viewport" content="width=device-width, initial-scale=1.0,initial-scale=1.0,minimum-scale=1.0, maximum-scale=1.0,user-scalable=no"> 2. introduce reset.css to solve different styles of mobile phones. @charset "utf-8";html{background-color:#fff;color:#0 ...

Posted by shann on Wed, 02 Oct 2019 13:08:12 +0200

Implementation of node.js + koa2 + https+ssl code for interface verification of public platform test number

Novice beginner node.js for development, in the application for access to the public platform development test number, because the official samples only for PHP and java and other ways of code, and node beginners do not understand, when submitted to the interface test URL, often unsuccessful, indicating "configuration failure", here i ...

Posted by r00tk1LL on Tue, 01 Oct 2019 15:10:43 +0200