Development Readiness: Chrome browser, require.js module management, Swiper plugin, iconfont icon, Sass
Reference Blog:http://www.haorooms.com/
Front-end development considerations
1. About META attributes
<meta name= "viewport" content= "width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=0" >
Viewport is the viewable area
Width=device-width width is the width of the device screen (in pixels);
Height=device-height height is the height of the device screen (pixels);
Initial-scale the initial scaling ratio;
Minimum-scale allows the user to zoom to the minimum scale;
Maximum-scale The maximum scale that allows the user to zoom in;
User-scalable whether the user can scale manually.
More
2, Format-detection
<meta name= "format-detection" content= "Telephone=no"/>
Telephone=no banned the conversion of numbers to dial-up links!
3, <meta name= "apple-mobile-web-app-capable" content= "yes"/>
The META function is to delete the default Apple toolbar and menu bar. The content has two values "yes" and "no", and when we need to display the toolbar and menu bar, the row meta is not added, the default is display.
4, <meta name= "Apple-mobile-web-app-status-bar-style" content= "Default"/>
<meta name= "Apple-mobile-web-app-status-bar-style" content= "Black"/>
<meta name= "Apple-mobile-web-app-status-bar-style" content= "Black-translucent"/>
The effect is to control the status bar display style
5, Unit REM
REM is relative to the root element
CMD and AMD
Both are JavaScript modular development specifications, but for the dependent modules, AMD is executed in advance (also can be deferred execution), CMD is deferred execution, and the CMD is highly dependent on the nearest, AMD respected relying on the predecessor.
Project Demo
First mobile-side project