search
HomeWeChat AppletMini Program DevelopmentWhat is the difference between mini programs and ordinary web development?

The main development language for small programs is JavaScript. The development of small programs is very similar to ordinary web development. For front-end developers, the cost of migrating from web development to mini program development is not high, but there are still some differences between the two.

The web page development rendering thread and the script thread are mutually exclusive, which is why long-term script running may cause the page to lose response; in small programs, the two are separated and run in different in thread. Web developers can use the DOM API exposed by various browsers to select and operate DOM.

The logic layer and rendering layer of the applet are separated. The logic layer runs in JSCore and does not have a complete browser object, so it lacks related DOM API and BOM API. This difference causes some libraries that are very familiar to front-end development, such as jQuery, Zepto, etc., to be unable to run in small programs. At the same time, the JSCore environment is different from the NodeJS environment, so some NPM packages cannot be run in small programs.

The environment that web developers need to face is a variety of browsers. On the PC side, they need to face IE, Chrome, QQ browser, etc.; on the mobile side, they need to face Safari, Chrome, iOS, and Android Various WebViews in the system. What you need to face during the development process of mini programs are the WeChat clients of the two major operating systems iOS and Android, as well as mini program developer tools for assisting development. The three major operating environments of mini programs are also different, as shown in the table 1 shown.

Table 1 Running environment of the mini program

Running environment Logical layer Rendering layer
iOS JavaScriptCore WKWebView
Android V8 Chromium Customized Kernel
Mini Program Developer Tools NWJS Chrome WebView

Recommended tutorial: "WeChat Mini Program"

The above is the detailed content of What is the difference between mini programs and ordinary web development?. For more information, please follow other related articles on the PHP Chinese website!

Statement
This article is reproduced at:简书. If there is any infringement, please contact admin@php.cn delete

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

MinGW - Minimalist GNU for Windows

MinGW - Minimalist GNU for Windows

This project is in the process of being migrated to osdn.net/projects/mingw, you can continue to follow us there. MinGW: A native Windows port of the GNU Compiler Collection (GCC), freely distributable import libraries and header files for building native Windows applications; includes extensions to the MSVC runtime to support C99 functionality. All MinGW software can run on 64-bit Windows platforms.

SublimeText3 English version

SublimeText3 English version

Recommended: Win version, supports code prompts!

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

VSCode Windows 64-bit Download

VSCode Windows 64-bit Download

A free and powerful IDE editor launched by Microsoft

DVWA

DVWA

Damn Vulnerable Web App (DVWA) is a PHP/MySQL web application that is very vulnerable. Its main goals are to be an aid for security professionals to test their skills and tools in a legal environment, to help web developers better understand the process of securing web applications, and to help teachers/students teach/learn in a classroom environment Web application security. The goal of DVWA is to practice some of the most common web vulnerabilities through a simple and straightforward interface, with varying degrees of difficulty. Please note that this software