3.3.2 AngularJS

AngularJS is a Javascript framework developed by Google with a focus on single page applications, so-called SPA. AngularJS therefore has lots of tools when it comes to working with asynchronous load (AJAX).

AngularJS is built around the MVC design pattern, a development approach that contains 3 main components:

  • Model (M) for data logic.
  • View (V) for display logic (Usually in HTML).
  • Controller (C) for applications logic e.g. Controls the application.

If you want more information about AngularJS you can find it at their website at https://angularjs.org/

With SmartWeb users we primarily uses AngularJS to manage and generate everything in the product list. Altough we also use it for listing the products, sorting the products and scrolling of the products. It is also used for managing the structure and column boxes; calendar and top products.

If you want more information about how AngularJS functions with SmartWeb, you can look at unminified Javascript code that can be found in 2 files of the product list and 1 file for each of the following: Structure and Column boxes.

Below you can see a list of Javascript files that are built with AngularJS:

  • /source/js/app/platform.app.js
  • /modules/product/assets/js/productlist.app.js
  • /modules/column/assets/js/module-calendar.js
  • /modules/column/assets/js/module-topproducts.js