Package Data | |
---|---|
Maintainer Username: | rmoreas |
Maintainer Contact: | sven.peremans@gmail.com (Sven Peremans) |
Package Create Date: | 2016-03-15 |
Package Last Update: | 2017-01-27 |
Language: | PHP |
License: | Unknown |
Last Refreshed: | 2024-11-19 03:00:48 |
Package Statistics | |
---|---|
Total Downloads: | 24 |
Monthly Downloads: | 0 |
Daily Downloads: | 0 |
Total Stars: | 1 |
Total Watchers: | 1 |
Total Forks: | 0 |
Total Open Issues: | 0 |
Laravel package providing ready to use template files to mimic the 2016 KU Leuven web layout.
This package should be considered as a boilerplate. It is intended to be installed and configured just once per project. Afterwards, updates will not be reflected automatically to your template files.
First install a fresh Laravel
composer create-project laravel/laravel myapp 5.3;
; or: "laravel new --5.3", but as on day of writing, option for 5.3 is not yet supported
And don't forget to let the www root point to the myapp/public/ directory.
Install the package and publish the files to your resources
composer require kuleuven/laravel-template;
Add the following sevice provider to your app.php :
Screenager\KULeuvenBoilerplate\KULeuvenBoilerplateServiceProvider::class,
Add following line to the classmap in your root composer.json file
"app/Helpers"
Then run
php artisan vendor:publish --provider="Screenager\KULeuvenBoilerplate\KULeuvenBoilerplateServiceProvider" --force;
composer dump-autoload;
npm install;
bower install;
gulp;
If "npm install" doesn't work, try "sudo npm install".
Finally, add following lines to .env and fill in the correct values
APP_URL=http://www.myapp.com
APP_NAME="My app"
SUB_LAYOUT=default # options : default, intranet, hosted-by, kulak, landingpage
GOOGLE_ANALYTICS_ENABLED=false
GOOGLE_ANALYTICS_TRACKING_ID=
You can now go extending the published layout to your needs!
The template is optimized to work together with following Laravel vendors. All are entirely optional.
laravel-menu is a powerful package to build and display a menu structure.
laravel-breadcrumbs is not maintained any longer, but can still be used as a tool to dynamically build a breadcrumb structure.
To support the KU Leuven layout, after installation, change the 'view' parameter of the config/breadcrumbs.php file to
'view' => 'layouts.kul_2016.partials.breadcrumbs.bootstrap4',
stevenmaguire/laravel-middleware-csp allows you to serve a policy file (CSP) to browsers telling them which frontend resources are safe to be loaded on your webpage.
mcamara/laravel-localization is a powerful extension for the supporting multiple languages in Laravel.
Laravel Collective provides an easier way to build forms.
Purifier comes with a method "clean" to selectively filter HTML from a string.
As this package serves as a boilerplate, fetching updates won't have effect to your layout, because the only way to alter the resources is to republish these package files which might probably overwrite your customizations you made for your app.
Running "gulp" again however, will fetch the latest HTML and CSS of the templates from ICTS. This is intended, as the ICTS template files are still in development. Also, this way the university related menu items in the header and footer of the layout are brought to their latest version in accordance with the other KU Leuven websites.
You might want to split the gulp command into a command to update your CSS/JS, and one to fetch the latest ICTS resources, but this is entirely up to you.
This boilerplate was made to support an info session at the university. It still needs some cleanup, such as a cleaner gulpfile.js and the use of Laravel facades.
Help is appreciated!