digitlab/adaptive-view

Adaptive views for Laravel.

v1.1.0 2016-03-04 14:44 UTC

This package is not auto-updated.

Last update: 2024-10-26 19:32:29 UTC


README

StyleCI Build Status Total Downloads Latest Stable Version License

An adaptive view extension for Laravel.

Installation

Install using composer:

composer require digitlab/adaptive-view

Follow the instructions in setting up Agent.

Add the service provider in app/config/app.php:

DigitLab\AdaptiveView\AdaptiveViewServiceProvider::class,

Usage

You can create a mobile view with the .mobile.blade.php extension. Similarly you can create tablet views with the .tablet.blade.php extension. Mobile and tablet views will fallback to normal views if they do not exist.

Troubleshooting

  • Check that AdaptiveViewServiceProvider is registered as soon after the ViewServiceProvider as possible. Invoking the view factory before registering AdaptiveViewServiceProvider will cause it not to work.

License

Adaptive View is licensed under The MIT License (MIT).