geowrgetudor / laravel-tiny-blog
A tiny blog package for Laravel
Fund package maintenance!
George Tudor
Installs: 6
Dependents: 0
Suggesters: 0
Security: 0
Stars: 4
Watchers: 1
Forks: 0
Open Issues: 1
Language:Blade
Requires
- php: ^8.1|^8.2|^8.3
- calebporzio/sushi: ^2.4
- graham-campbell/markdown: ^15.1
- illuminate/contracts: ^10.0|^11.0
- spatie/laravel-package-tools: ^1.14.0
Requires (Dev)
- laravel/pint: ^1.0
- nunomaduro/collision: ^7.8|^8.0
- orchestra/testbench: ^8.8|^9.0
- pestphp/pest: ^2.20
- pestphp/pest-plugin-arch: ^2.0
- pestphp/pest-plugin-laravel: ^2.0
This package is auto-updated.
Last update: 2024-11-29 06:47:37 UTC
README
A tiny markdown blog package for Laravel
Quickly add a Markdown blog to your Laravel app.
Installation
You can install the package via composer:
composer require geowrgetudor/laravel-tiny-blog
Initialize the blog by running the following command. A directory called content
will be create in the root of your project. That's where your markdown article will be stored.
php artisan tinyblog:init
Publish the assets:
php artisan tinyblog:publish
Publish the config file and configure it however you like it:
php artisan vendor:publish --tag="tiny-blog-config"
If you want some sample articles, you can publish our examples using:
php artisan tinyblog:example
Optionally, you can publish the views to customize and/or extend them
php artisan vendor:publish --tag="tiny-blog-views"
Creating new articles
use Geow\TinyBlog\Models\Article; Article::create([ 'title' => 'My first article', 'description' => 'Trying out Tiny Blog', 'img' => 'https://images.unsplash.com/photo-1682686579688-c2ba945eda0e?q=80&w=500&auto=format&fit=crop', 'content' => '## Hello world', // should be markdown content 'author' => 'George Tudor', 'date' => now()->toDateTimeString(), ]);
Views
You can access the blog at your-domain.com/blog
. You can change the route name in tiny-config.php
config file.
Testing
composer test
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
Credits
License
The MIT License (MIT). Please see License File for more information.