Front-end Config Files


All Javascript files are located in apps/block_scout_web/assets/js. The main file is app.js. This file imports all javascript used in the application. If you want to create a new JS file consider creating in /js/pages or /js/lib, as follows:
This folder contains all scripts usable for any page or as helpers to some component.
This folder contains the scripts that are page-specific.
This project uses Redux to control the state in some pages. There are pages with real-time events that use Phoenix channels, e.g. Address page. The page state changes often depending on which events it is listening to. Redux is also used to load some contents asynchronously, see async_listing_load.js.
To understand how to build new pages that require Redux, see the redux_helpers.js file.
Export as PDF
Copy link