Home Metronic Hire Us Buy Now
The World’s #1 Bootstrap 4 & 5 HTML, Angular 11, React, VueJS & Laravel
Admin Dashboard Theme

## Laravel: File Structure

### Overview

Laravel is a web application framework with expressive, elegant syntax. We believe development must be an enjoyable, creative experience to be truly fulfilling. Laravel attempts to take the pain out of development by easing common tasks used in the majority of web projects.

We, at KeenThemes, have implemented our multipurpose dashboard application theme Metronic with this amazing PHP framework so that Laravel developers can concentrate on application and not caring much about theme-to-framework integration.

Currently we provide only `demo1` version of theme with comprehensive layout configuration and set of views.

### Laravel with Metronic Demo Pages

The application source is located in `[metronic]/theme/html_laravel/`

Path | Description
--- | ---
theme | The Metronic theme pacakge.
html_laravel | Laravel application demo
demo1 | demo1 base folder for Laravel application
skeleton | Laravel application with sample pages.

### Application Directory Structure

Application specific files and folders for Metronic+Laravel integration on top of standard Laravel directory structure. We will not list all standard files/directories if they are not related to this application. Refer to Laravel directory structure documentation for framework defaults.

Path | Description
--- | ---
app | The App Directory. Controllers and other running classes are placed here.
Classes | Custom classes directory.
Theme | Metronic PHP Classes folder. None of the Classes inside need to be edited for application to run.
Init.php | Initialises layouts and components.
Menu.php | Renders vertical (aside) and horizontal (header) menus.
Metronic.php | The heart of theme functionality. Helps rendering SVG icons, loads CSS and JS components, classes and functions.
Http | Requests, Controllers etc.
Controllers | Application Controllers live here.
Controller.php | Main application abstract Controller. Usually extends other Controllers.
PagesController.php | Demo pages controller for this application. Containes few methods to load demo pages. Can be edited or removed at courtesy of developers.
config | Configuration files are located here. Here we also placed configurational files that are required for layouts and menus.
layout.php | Main layout configuration. Edit values to adjust theme layouts the way you like. Please refer to layout builder to see layout configuration examples.
menu_aside.php | Aside menu configuration.
menu_header.php | Header menu configuration.
public | Here will be placed publicly accessible assets and files.
resources | Application resources and view files are located here. From it's subfolders and files npm will build public assets, app will renders views and layouts.
js | JavaScript configuration loaders for compiler (laravel-mix and webpack).
lang | Default Laravel translation fileset.
metronic | Theme specific global assets and plugins source.
plugins | Custom plugins and modules source.
sass | SCSS configuration loaders are located here.
views | Application view files live here. Laravel is set to renders views from this folder by default.
layout | Theme layout files and partials for application.
base | Base layout template components.
_aside.blade.php | Side menu partial.
_content.blade.php | Content section template.
_footer.blade.php | Footer pertial.
_header-mobile.blade.php | Mobile header toggle partial.
_header.blade.php | Header template.
_layout.blade.php | Main layout template.
patials | Partials for layouts and pages. Mostly configured from `config/layout.php`
extras | Dropdowns, Offcanvas panels and other includable page elements.
subheader | Page subheader variaiton partials.
pages | Demo pages. All loaded from `App\Controllers\PagesController.php` for which routes are defined in `routes/web.php`
icons | Contains all available icons pages.
custom-icons.blade.php | Page view file which contains custom icons usage examples. Route: `icons/custom-icons`
flaticon.blade.php | Page view file which contains flaticon usage examples. Route: `icons/flaticon`
fontawesome.blade.php | Page view file which contains fontawesome icons usage examples. Route: `icons/fontawesome`
lineawesome.blade.php | Page view file which contains lineawesome icons usage examples. Route: `icons/lineawesome`
socicons.blade.php | Page view file which contains socicons icons usage examples. Route: `icons/socicons`
svg.blade.php | Page view file which contains svg icons usage examples. Route: `icons/svg`
widgets | Demo widgets for dashboard page.
dashboard.blade.php | Dashboard page view file. Route: `/`
datatables.blade.php | Datatables example page view. Route: `/datatables`
jquery-mask.blade.php | Jquery mask plugin example page view. Route: `/jquerymask`
ktdatatables.blade.php | Metronic Custom Datatables page view. Route: `/ktdatatables`
select2.blade.php | Select2 plugin example page view. Route: `/select2`
package.json | This file contains meta data about app or module. Most importantly, it includes the list of dependencies to install from npm when running `npm install`.
package-lock.json | package-lock.json is automatically generated for any operations where npm modifies either the node_modules tree, or package.json
webpack.mix.js | Webpack confiand Laravel Mix configuration - defines how are assets are compiled. Handle with care!