Git Product home page Git Product logo

laravel-starter-template's Introduction

MIT Licensed

laravel starter Template, to save your time when You start with new scalable Laravel projects with many features.

Based on Laravel8.x

backend-rtl2

Requirements

please be careful about the Requirements:-

  • Highly Recommended to use it with PHP v7.4 or up, and ensure that , the version used by composer is 7.4 to Avoid any problems with contianed packages.
  • All packages work probably with PHP 7.2, BUT PHP7.4 and The exif extension is required for Spatie Media Library.

IMPORTANT NOTE

if you have PHP7.4 you will use this template with all features without any problems, but if your PHP under 7.4 you Can NOT use it with Spatie Media Library, SO you must uninstall Spatie Media Library or Upgrade your php to 7.4 or UP see more about Spatie Media Library here

Custom Commands

I have created a number of custom commands for the project. The commands are listed below with a brief about the use of it.

Clear All Cache

composer clear-all

this is a shortcut command clear all cache including config, route and more

Code Style Fix

composer fix-cs

apply the code style fix by this command.

Features

The laravel-starter-template comes with a number of features which are the most common in almost all the applications. It is a template project which means it is intended to build in a way that it can be used for other projects.

It is a modular application, and a number of modules are installed by default. It will be helpful to use it as a base for the future applications.

  • Admin feature and public views are completely separated as Backend and Frontend namespace.
  • Major feature are developed as Modules. Module like Posts, Comments, Tags are separated from the core features like User, Role, Permission

Core Features

  • User Authentication
  • Social Login
    • Google
    • Facebook
    • Github
    • Build in a way adding more is much easy now
  • User Profile with Avatar
    • Separate User Profile table
  • Role-Permissions for Users
  • Dynamic Menu System
  • Backend Theme
    • Bootstrap 4, CoreUI
    • Fontawesome 5
  • Frontend Theme
    • Bootstrap 4, Impact Design Kit
    • Fontawesome 5
  • Article Module
    • Posts
    • Categories
    • Tags
    • Comments
    • wysiwyg editor
    • File browser
  • Application Settings
  • External Libraries
    • Bootstrap 4
    • Fontawesome 5
    • CoreUI
    • Impact Design Kit
    • Select2
    • Date Time Picker
  • Backup (Source, Files, Database as Zip)
  • Log Viewer
  • Built by Modules (microservices) Archticture
  • Notification
    • Dashboard and details view
  • RSS Feed

Additional features

  • Well Structure of Scalable Laravel Projects (Modules Structure, Folders,Routes,Controllers,Views)
  • Language Switcher Frontend and Backend (with middleware)
  • RTL Support by one click ,Just change language to Arabic , it will change Direction to RTL
  • Eloquent models translatable with spatie/laravel-translatable
  • SEO Friendly by Forcing all frontend routes with locale prefix
  • with Spatie Media Library and conversitions
  • with Yajra DataTables
  • with infyom Laravel Generator
  • All Stubs are ready to customize

User Guide

Installation

Follow the steps mentioned below to install and run the project.

  1. Clone or download the repository git clone https://github.com/omaralalwi/laravel-starter-template
  2. Go to the project directory and run composer install
  3. Create .env file by copying the .env.example. You may use the command to do that cp .env.example .env
  4. Update the database name and credentials in .env file
  5. Run the command php artisan migrate --seed
  6. Link storage directory: php artisan storage:link
  7. generate encryption key to app: php artisan key:generate
  8. You may create a virtualhost entry to access the application or run php artisan serve from the project root and visit http://127.0.0.1:8000
  9. Login to Admin Panel localhost:8000/admin Username: [email protected] Password: secret

After creating the new permissions use the following commands to update cashed permissions.

php artisan cache:forget spatie.permission.cache

Icons

FontAwesome & CoreUI Icons, two different font icon library is installed for the Backend theme and only FontAwesome for the Frontend. For both of the cases we used the free version. You may install the pro version separately for your own project.

Making a model translatable

According to spaite pakcage:-

  • to make default local open config/translatable and edit 'fallback_locale' => null, to your prefferd local like: 'fallback_locale' => ar, if you prefer Arabic.
  • NOTE: This prefferd local for translated models not for App local, this mean if you insert product with many languages the primary language will be ar.

The required steps to make a model translatable are:

  • First, you need to add the Spatie\Translatable\HasTranslations-trait.
  • Next, you should create a public property $translatable which holds an array with all the names of attributes you wish to make translatable.
  • Finally, you should make sure that all translatable attributes are set to the text-datatype in your database. If your database supports json-columns, use that.

Here's an example of a prepared model:

use Illuminate\Database\Eloquent\Model;
use Spatie\Translatable\HasTranslations;

class NewsItem extends Model
{
    use HasTranslations;
    
    public $translatable = ['name'];
}
  • All Toturials for Translation here , you do't need to install it , it is preinstalled, Just see Toturials.

insert Demo Data in DB

to login with Admin You must add it by run the follwing command

php artisan db:seed

Then insert Demo Data For Posts and comments and Tags and another Models , Run the follwing Command

php artisan starter:insert-demo-data --fresh

Dashboard Creditional 
Super Admin
User: [email protected]
Pass: secret

User
User: [email protected]
Pass: secret

Screenshots

these some screenshotes

backend-ltr

backend-rtl

backend-rtl2

backend-rtl3

frontend1

frontend2

Thanks

All Core Features taken from Mr. nasirkhan

Development

This project will continue to evolve and grow, until it becomes the first Laravel Starter Template, follwo me to still up to date.

Credits

Contact ME Twitter Contact ME Linkedin Hire me Freelancer OR Contact by Email

COMING SOON

GlobalTrans will be available SOON, it is A Laravel Package to make Eloquent models translatable to Unlimited Languages

License

This Project is open sourced software licensed under the MIT license.

laravel-starter-template's People

Contributors

omaralalwi avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.