# dbapp **Repository Path**: oyakuki/dbapp ## Basic Information - **Project Name**: dbapp - **Description**: 微信小程序,仿豆瓣精选 - **Primary Language**: 微信 - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 1 - **Forks**: 0 - **Created**: 2016-12-28 - **Last Updated**: 2020-12-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README 豆瓣精选文章 wechat小程序 分为以下几个页面: 1、欢迎页面 微信小程序自带页面 2、登录页面 3、注册页面 4、忘记密码页面 5、主页面 6、文章列表页面 7、文章详情页面 8、个人中心页面 微信小程序初始化 1、新建空的文件夹----自动创建基本配置 2、新建页面的时候---在app.json里面创建页面的路由---自动创建新的页面的文件夹 3、每一个页面的文件夹---wxml、wxss、js、json image mode 4种缩放模式(scaleToFill,aspectFit,aspectFill,widthFix) 9种剪裁模式 页面链接 navigator url(应用内的页面跳转) open-type(redirect,navigate,switchTab) 模块化概念 将一些公共的代码抽离成为一个单独的 js 文件,作为一个模块。模块只有通过 module.exports 或者 exports 才能对外暴露接口 微信里面相对应的文件是utils/utils.js 模块通过 module.exports 或者 exports 才能对外暴露接口 module.exports.sayHello = sayHello 模块的使用 在需要使用这些模块的文件中,使用 require(path) 将公共代码引入 var common = require('common.js')