Package managers are tools that allow you to manage dependencies in your project. Some bundlers commonly used in React applications include Webpack and Browserify. Bundlersīundlers take JavaScript and CSS code written as separate modules (often hundreds of them), and combine them together into a few files better optimized for the browsers. Babel is the compiler most commonly used with React. The most common use case is to take ES6 syntax and transform it into syntax that older browsers are capable of interpreting. CompilersĪ JavaScript compiler takes JavaScript code, transforms it and returns JavaScript code in a different format. You can learn more about specific versions here. The ES6 version (also known as ES2015) includes many additions to the previous versions such as: arrow functions, classes, template literals, let and const statements. These acronyms all refer to the most recent versions of the ECMAScript Language Specification standard, which the JavaScript language is an implementation of. In fact, this is exactly how React is being used at Facebook. Code written in React can coexist peacefully with markup rendered on the server by something like PHP, or with other client-side libraries. React can also be used for enhancing small parts of existing websites with additional interactivity. Though you may build a single-page application in React, it is not a requirement. Any interactions with the page or subsequent pages do not require a round trip to the server which means the page is not reloaded. A single-page application is an application that loads a single HTML page and all the necessary assets (such as JavaScript and CSS) required for the application to run.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |