Skip to content

ralfarishi/larablog

Repository files navigation

Installation

  1. Clone this repo & update dependencies using composer.
$ cd larablog
$ composer update
  1. Install NPM dependencies:
$ npm install
  1. Build Vite using NPM:
$ npm run build
  1. Copy the .env.example file.
$ cp .env.example .env
  1. Create a new MySQL database dan set up the new database in .env file.
DB_DATABASE=database_name
DB_USERNAME=root
DB_PASSWORD=
  1. Open the seeder file located in database/seeders/AdminSeeder.php for admin login credential.
$name = 'admin'; // username
DB::table('users')->insert([
  'name' => $name,
  'slug' => Str::slug($name),
  'email' => 'admin@jewepe.com', // email
  'role' => 'admin', // role
  'password' => Hash::make("12345678") // password
]);
  1. Create the application key:
$ php artisan key:generate
  1. Run migration & seed:
$ php artisan migrate --seed
  1. Run the project:
$ php artisan serve

Features

  • Home
    • Login & register.
    • Search article.
    • Add comment on an article.
    • Filter article by category, tag, or user.
  • Dashboard
    • Roles [Admin/Writter].
    • CRUD article.
    • Comment management.
    • Create & delete category. (Admin only)
    • User management. (Admin only)
    • Login history. (Admin only)