PHPackages                             dorantes/laravel-pug - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Templating &amp; Views](/categories/templating)
4. /
5. dorantes/laravel-pug

ActiveLibrary[Templating &amp; Views](/categories/templating)

dorantes/laravel-pug
====================

Pug view adapter for Laravel 4

1.2.2(9y ago)017MITPHPPHP &gt;=5.3.3

Since Jul 20Pushed 9y ago1 watchersCompare

[ Source](https://github.com/WCLab/laravel-pug)[ Packagist](https://packagist.org/packages/dorantes/laravel-pug)[ RSS](/packages/dorantes-laravel-pug/feed)WikiDiscussions master Synced 2mo ago

READMEChangelog (2)Dependencies (3)Versions (6)Used By (0)

Laravel Pug
===========

[](#laravel-pug)

A small package that adds support for compiling Pug (Jade) templates to Laravel via [Pug.php](https://github.com/pug-php/pug). Both vanilla php and [Blade syntax](http://laravel.com/docs/5.2/templates#blade-templating) is supported within the view.

Installation
------------

[](#installation)

1. Run `composer require dts/laravel-pug`
2. Add the service provider to your app.php providers: `DTS\LaravelPug\ServiceProvider,`

Configuration
-------------

[](#configuration)

All [Pug.php](https://github.com/pug-php/pug) config options are passed through via a Laravel config array.

- Publish the config file with `php artisan config:publish dts/laravel-pug  --path=vendor/dts/laravel-pug/config` and edit at /app/config/packages/dts/laravel-pug/config.php

Usage
-----

[](#usage)

Laravel Pug registers the ".pug", ".pug.php", ".pug.blade", and ".pug.blade.php" as well as the ".jade", ".jade.php", ".jade.blade", and ".jade.blade.php" extensions with Laravel and forwards compile requests on to Pug.php. It compiles your Pug templates in the same way as Blade templates; the compiled template is put in your storage directory. Thus, you don't suffer compile times on every page load.

In other words, just put your Pug files in the regular views directory and name them like "whatever.pug". You reference them in Laravel like normal:

- `View::make('home.whatever')` for `app/views/home/whatever.pug`

The Pug view files can work side-by-side with regular PHP views. To use Blade templating within your Pug, just name the files with ".pug.blade" or ".pug.blade.php" extensions.

Extending Layouts / Include Sub-views
-------------------------------------

[](#extending-layouts--include-sub-views)

Default root directory for templates is `app/views`, so from any template any deep in the directory, you can use absolute paths to get other pug files from the root: `extends /layouts/main` will extends the file `resources/views/layouts/main.(pug|jade)`, `include /partial/foo/bar`, will include `resources/views/partial/foo/bar.(pug|jade)`. You can use the `basedir` option to set the root to an other directory. Paths that does not start with a slash will be resolved relatively to the current template file.

Histoy
------

[](#histoy)

Read the Github [project releases](https://github.com/WClab/laravel-pug/releases) for release notes.

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity62

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~67 days

Total

5

Last Release

3315d ago

PHP version history (2 changes)1.0.0PHP &gt;=5.4.0

1.2.1PHP &gt;=5.3.3

### Community

Maintainers

![](https://www.gravatar.com/avatar/1d5774c18c65c88221dae93554f0b250e77f2aaabdb80caf776aec4f9abba684?d=identicon)[fdorantesm](/maintainers/fdorantesm)

---

Top Contributors

[![weotch](https://avatars.githubusercontent.com/u/77567?v=4)](https://github.com/weotch "weotch (10 commits)")[![wpdesigns](https://avatars.githubusercontent.com/u/16109256?v=4)](https://github.com/wpdesigns "wpdesigns (8 commits)")[![kylekatarnls](https://avatars.githubusercontent.com/u/5966783?v=4)](https://github.com/kylekatarnls "kylekatarnls (2 commits)")[![Rivsen](https://avatars.githubusercontent.com/u/762701?v=4)](https://github.com/Rivsen "Rivsen (1 commits)")[![thelucre](https://avatars.githubusercontent.com/u/4340866?v=4)](https://github.com/thelucre "thelucre (1 commits)")

### Embed Badge

![Health badge](/badges/dorantes-laravel-pug/health.svg)

```
[![Health](https://phpackages.com/badges/dorantes-laravel-pug/health.svg)](https://phpackages.com/packages/dorantes-laravel-pug)
```

###  Alternatives

[rcrowe/twigbridge

Adds the power of Twig to Laravel

9105.9M50](/packages/rcrowe-twigbridge)[tightenco/jigsaw

Simple static sites with Laravel's Blade.

2.2k438.5k29](/packages/tightenco-jigsaw)[roots/acorn

Framework for Roots WordPress projects built with Laravel components.

9682.1M97](/packages/roots-acorn)[moonshine/moonshine

Laravel administration panel

1.3k217.1k59](/packages/moonshine-moonshine)[livewire/blaze

A tool for optimizing Blade component performance by folding them into parent templates

688221.3k17](/packages/livewire-blaze)[bkwld/laravel-pug

Pug view adapter for Laravel

15967.4k2](/packages/bkwld-laravel-pug)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
