The Media.php class, loaded in the application core, was created to distribute and include public files in our views.
<?php Media::css(); ?> // Loads the framework's base CSS files
<?php Media::js(); ?> // Loads the framework's base JS files
<?php Media::addCss('estilos.css'); ?> // Adds view-specific CSS
<?php Media::addJs('main.js'); ?> // Adds view-specific JS
Default path:
* components/component/views/public/css/archivo.css
* components/component/views/public/js/archivo.js
The framework's base files should preferably be loaded before the </head> tag.
JS and CSS can also be included through the components.xml configuration file.