nawarian/jigsaw-sitemap-plugin

A sitemap generator plugin for Tightenco's Jigsaw

dev-master 2019-04-27 19:06 UTC

This package is auto-updated.

Last update: 2024-03-28 06:02:00 UTC


README

Build Status codecov

Jigsaw Sitemap Plugin is an easy and straight forward plugin to be used on Jigsaw's afterBuild event.

It fetches all generated pages and generates a sitemap file containing such entries based on configurations.

Usage

On your Jigsaw project, require this package:

$ composer require nawarian/jigsaw-sitemap-plugin

On your bootstrap.php file, register the Listener:

use Nawarian\JigsawSitemapPlugin\Listener\SitemapListener;

/** @var $container \Illuminate\Container\Container */
/** @var $events \TightenCo\Jigsaw\Events\EventBus */

$events->afterBuild([SitemapListener::class]);

After running the build you should see a sitemap.xml file inside build's output folder.