# Elevate Your Blogging Experience with firefly/filament-blog in Laravel

By Dinesh Uprety
Published: 2024-04-22
Updated: 2024-04-22
Canonical: https://laranepal.com/blog/elevate-your-blogging-experience-with-fireflyfilament-blog-in-laravel

# Introduction

The [firefly/filament-blog](https://github.com/thefireflytech/filament-blog) package is an advanced blogging solution
designed for the Filament Admin Panel. It offers a range of features to enhance your blog posts, including SEO meta
extensions, scheduled posts, social media sharing, and more.

# Prerequisites

Before you begin, ensure you have Laravel 11 and Filament 3.x installed in your project. If not, you can install them
using the following commands:

```bash
composer require filament/filament:"^3.2" -W
php artisan filament:install --panels
```

# Installation

To install the firefly/filament-blog package, run the following command:

```bash
composer require firefly/filament-blog
```

# Configuration

After installation, publish the configuration and migration files with:

```bash
php artisan filament-blog:install
```
This command will publish `filamentblog.php` config file and `create_blog_tables.php` migration file.
```php
<?php

/**
 * |--------------------------------------------------------------------------
 * | Set up your blog configuration
 * |--------------------------------------------------------------------------
 * |
 * | The route configuration is for setting up the route prefix and middleware.
 * | The user configuration is for setting up the user model and columns.
 * | The seo configuration is for setting up the default meta tags for the blog.
 * | The recaptcha configuration is for setting up the recaptcha for the blog.
 */

use Firefly\FilamentBlog\Models\User;

return [
    'route' => [ // [tl! collapse:start]
        'prefix' => 'blogs',
        'middleware' => ['web'],
//        'home' => [
//            'name' => 'filamentblog.home',
//            'url' => env('APP_URL'),
//        ],
        'login' => [
            'name' => 'filamentblog.post.login',
        ],
    ], // [tl! collapse:end]
    'user' => [ // [tl! collapse:start]
        'model' => User::class,
        'foreign_key' => 'user_id',
        'columns' => [
            'name' => 'name',
            'avatar' => 'profile_photo_path', // column name for avatar
        ],
    ], // [tl! collapse:end]
    'seo' => [
        'meta' => [
            'title' => 'Filament Blog',
            'description' => 'This is filament blog seo meta description',
            'keywords' => [],
        ],
    ],

    'recaptcha' => [
        'enabled' => false, // true or false
        'site_key' => env('RECAPTCHA_SITE_KEY'),
        'secret_key' => env('RECAPTCHA_SECRET_KEY'),
    ],
];
```

# Usage

With the **firefly/filament-blog** package installed, you can now access the blog management interface through the
Filament Admin Panel. Create, edit, and manage your posts with ease, utilizing the powerful features provided by the
package.

# Features

* **SEO Meta Extension**: Customize meta tags for each post to improve search engine visibility.

* **Post Scheduling**: Plan your content calendar by scheduling posts for future publication.

* **Social Media Integration**: Allow readers to share your content across social platforms.

* **Comment System**: Engage with your audience through an integrated commenting system.

* **Newsletter Subscription**: Grow your mailing list with newsletter sign-up forms.

* **Category Management**: Organize your posts with categories for easy navigation.

For a detailed walkthrough, refer to the [Official documentation](https://packagist.org/packages/firefly/filament-blog)
and
[GitHub repository](https://github.com/thefireflytech/filament-blog).

By following this guide, you'll be able to integrate the **firefly/filament-blog** package into your Laravel application,
enhancing your blog's functionality and user experience. Remember to keep your SEO data updated to ensure the best
visibility for your content.

# Demo
https://www.youtube.com/watch?v=8UkcAicQZUc

