Inspired by the JS status I saw in my enterprise this week, I wrote this article. 10 years ago, I never thought that JavaScript would become almost ubiquitous. Below are some of the reasons why you need to pay attention to JavaScript's original...
Inspired by the JS status I saw in my enterprise this week, I wrote this article. 10 years ago, I never thought that JavaScript would become almost ubiquitous. The following are the reasons why you need to pay attention to JavaScript.
First, I think one of the main reasons for the popularity of JavaScript is that JavaScript is very easy to access. It is relatively easy for beginners to learn JavaScript. It is very powerful for advanced users and can be used to build complex and reliable systems.
Second, we need to pay attention to JavaScript because today's JavaScript is everywhere.
You can use JavaScript For Development on almost all platforms: client applications, server-side business logic, embedded chips/Iot devices, management of build scripts and dependencies, etc.
However, this does not mean that you can use exactly the same code under any circumstances, but you can use the same skill-JavaScript development-to provide solutions that span multiple paradigms.
Client
JavaScript can be used to support client applications/user interfaces, as well as user interaction between many platforms and devices.
Web
Of course, JavaScript supports web. JavaScript is the basic scripting language for all web browsers.
Mobile
JavaScript can also be used to support mobile applications installed on local devices.
Apache Cordovn/PhoneGap -- you can use PhoneGap or Cordovn to create a locally installed web technology app. PhoneGap is the branch of Adobe's Cordovn brand, but from the developer's point of view, they are basically the same. Applications running on mobile devices have a web View, which allows you to build user interfaces in the same way as dynamic web applications. Although the user interface is implemented using HTML and CSS styles, all interactions are created using JavaScript.
React Native-web applications supported by JavaScript can not only have built-in web views. The React Native framework also allows developers to use JavaScript and declarative UI elements to write their applications and generate a local application that can run on mobile devices. During runtime, the logic is interpreted as JavaScript, but 100% of all (all UI elements) that interact with users are local, which provides a very high-quality user experience, it can also be used for iOS and Android applications.
Unity 3D-with the Unity 3D engine, you can develop a rich and immersive mobile 3D simulation or gaming experience, even if it is fully supported by JavaScript.
NativeScript-a JavaScript framework that can be used to build cross-platform local iOS, Android, and Windows Mobile applications.
Desktop
Desktop applications are not excluded from JavaScript. Most desktop solutions fall into a classification similar to Apache Cordovn. The result is that the web View has a low API level and its content development is based on web technology.
Electron -- Node. js + Chromium desktop application container from GitHub
App. js -- Node + Chromium desktop application container
Nw. js -- another Node + Chromium desktop application container framework
CEF -- The Chromium Embedded Framework -- Embedded into The Framework of The Chrome browser built into The desktop application.
... And so on. By the way, I remember that Microsoft already has a solution for how to use HTML/JS to Build Windows applications, and there are more solutions, but now I cannot remember it.
In fact, some of my favorite desktop tools, such as Slack, Atom, and VS Code, are actually implemented based on web technology and HTML/JS.
Server
The most obvious thing is that Node. js-the JavaScript runtime that encapsulates Chrome's V8 JavaScript Engine-has made great progress in server-side development and enterprises. Node. js is supported by frameworks such as express. js and loopback. io, making it possible to develop servers and complex enterprise applications using JavaScript.
Iot
You can use JavaScript to develop headless apps that can run on Arduino, Raspberry Pi, or other small tablets. You can use JavaScript to manage infrastructure and IOT sensor information flows, you can also use JavaScript to write a chip program for an embedded system, which can be used to control the robot. You can even use JavaScript to support connecting a media center to a TV.
As I said ...... JavaScript is everywhere.
Ecosystem
You can not only build and run JavaScript applications everywhere. JavaScript also has a huge and prosperous developer ecosystem.
JavaScript is the most active language on GitHub. It is not only the most active of all code repositories, but also the most active of all push/commit.
-- Rod Boothby (@ rod11) February 11, September 10, 2015
However, this does not mean that JavaScript is the best language for everything. It does not mean that you can extract a piece of source code and run it on every device or context as you want.
However, you can use JavaScript to develop almost any type of devices/below. Of course, it cannot be written at once and runs everywhere. The React. js team uses learn once and write everywhere.
The above is why our programmers should pay attention to JavaScript content. For more information, see the PHP Chinese website (www.php1.cn )!