Download the PHP package salehhashemi/laravel-domain-expert without Composer

On this page you can find all versions of the php package salehhashemi/laravel-domain-expert. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-domain-expert

Laravel Domain Expert

Latest Version on Packagist Total Downloads GitHub Actions GitHub Code Style Action Status StyleCI

Laravel Domain Expert is a package that helps you create and manage domain-driven directory structures in your Laravel application. It automates the process of setting up a new domain with the necessary folders, a controller, and a simple route file with a route group and a domain prefix.

AI-Powered Domain Recommendation

Laravel Domain Expert includes an AI-powered domain recommendation feature that helps you automatically group and organize your existing controllers and models into domain-driven structures.

To use this feature, run the following command:

The AI will guess the purpose of your application and provide a well-structured organization without requiring any additional input from the user.

Sample output of AI system

Installation

To install Laravel Domain Expert, you can use Composer:

Usage

Creating a new domain

To create a new domain directory structure, run the following command:

Replace DomainName with the desired name for your domain.

The command will create a domain directory structure in your Laravel application, including a sample controller and a simple route file with a route group and a domain prefix.

Domain Structure

When you create a new domain using the php artisan make:domain DomainName command, the following directory structure will be generated:

This structure helps you organize your code in a domain-driven manner, making it easier to manage and maintain as your application grows.

Creating controllers within a domain

To create a new controller within a specific domain, use the -d or --domain flag:

or

When using the -d or --domain flag, you will be prompted to select the domain you'd like to create the controller in.

Other commands

You can do the same routine to make:

Auto-loading Routes and Views

The package includes built-in support for automatically loading routes and views for each domain. When your package is installed and the service provider is registered, the DomainAutoScanServiceProvider class will scan the Domains directory and automatically discover and load the route and view files for each domain.

Example: Calling views in controllers

To reference a view within a domain, use the domain name as the namespace, followed by two colons and the view file path. Here's an example of how to call a view in a controller:

Testing

Changelog

Please see CHANGELOG for more information what has changed recently.

Contributing

Please see CONTRIBUTING for details.

Credits

License

The MIT License (MIT). Please see License File for more information.


All versions of laravel-domain-expert with dependencies

PHP Build Version
Package Version
Requires php Version ^8.0
illuminate/support Version ^8.0|^9.0|^10.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package salehhashemi/laravel-domain-expert contains the following files

Loading the files please wait ....