Download the PHP package cyberbugz/dust without Composer

On this page you can find all versions of the php package cyberbugz/dust. 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 dust

Dust: Laravel Framework Base Package

Welcome to Dust, a modular framework base package for Laravel. Designed with developers in mind, Dust accelerates your Laravel project development by providing pre-configured tools, enhanced CLI commands, and a robust structure for modular architecture.

GitHub stars GitHub issues GitHub license


Table of Contents

  1. What Is Dust
  2. Why Use Dust
  3. Installation
  4. Usage
  5. File Structure
  6. Key Features
  7. Detailed Description of Components
    • Config
    • Base
    • Console
    • Http
    • Providers
    • Support
  8. Command Cheat Sheet
  9. Overview

🚀 What is Dust?

Dust is a developer-first Laravel package that brings modularity, reusability, and streamlined workflows to your Laravel projects. It acts as a base framework for new Laravel applications, providing pre-built functionalities and a clean starting point for scalable, maintainable, and efficient development.

🛠️ Key Benefits:


🎯 Why Use Dust?

Dust empowers Laravel developers to focus on building features rather than boilerplate code. By adopting Dust, you gain:


Ready to supercharge your Laravel development? Dive into Dust and unlock the power of modularity and automation!


Installation

To install the Dust package, use Composer:

After installation, publish the configuration file:


Usage

Start a new Laravel project using Dust:

  1. Define your modules and their components in the configuration file.
  2. Use Dust's CLI commands to scaffold controllers, models, migrations, and more.
  3. Leverage attribute-based routing to simplify route definitions.
  4. Integrate custom providers, traits, and helpers for modular development.

File Structure

Here’s a summary of the folder structure:


Key Features

Detailed Description of Components


Config

Base

Console

Description:

The Console folder provides a wide range of Artisan commands to scaffold and manage components in a modular Laravel environment. Below is a detailed explanation of each command.

Key Traits:

  1. AbsolutePathChecker:
    • Ensures commands resolve absolute paths for modules.
    • Provides support for custom stubs based on the module context.
  2. GuardChecker:
    • Validates guard options against Laravel's auth configuration.
    • Ensures commands only accept valid guard inputs.
  3. ModelQualifier:
    • Dynamically resolves model namespaces based on module context or default Laravel directories.
    • Simplifies interaction with models across different modules.
  4. OptionsExtender:
    • Adds common command options like:
      • --module: Specify the target module for the command.
      • --absolute: Use absolute paths for module resolution.
      • --guard: Define a specific guard environment.
    • Ensures consistency in how commands handle options.
  5. SignatureExtender:
    • Appends additional options or arguments to the command signature.
    • Enables modular flexibility for commands.

Commands and Features:

The Http folder provides a robust set of tools to enhance Laravel’s routing, response handling, and middleware workflows. It introduces attributes, enums, and custom responses to support a declarative and modular approach to managing HTTP operations.


1. Attributes

Attributes are PHP metadata annotations that define routing, middleware, guards, and other route-specific behaviors. These attributes streamline route configuration by replacing traditional route registration methods.


2. Enums

Enums provide strongly typed constants for various HTTP-related operations, ensuring clarity and preventing errors in route definitions.


3. Responses


4. Exceptions


5. Key Benefits

  1. Attribute-Based Routing:

    • Eliminates the need for manual route registration.
    • Provides a declarative syntax for defining routes, middleware, guards, and prefixes.
    • Ensures routes are self-contained and easy to read.
  2. Standardized Error Responses:

    • Simplifies error handling with a consistent JSON structure.
    • Reduces boilerplate code for custom error formatting.
  3. Strongly Typed Enums:

    • Prevents errors by restricting invalid HTTP methods or route configurations.
    • Improves code readability and maintainability.
  4. Modular Design:
    • Enables guard and prefix-specific routing for modules.
    • Supports both attribute-based and file-based routing strategies.

Example Usage

Providers

The Providers folder encapsulates the service providers essential to extending Laravel's core functionality and supporting the modular architecture of this package. These providers handle everything from route management to event discovery and Artisan commands, ensuring the package integrates seamlessly with Laravel's ecosystem.


1. DustServiceProvider

The DustServiceProvider is the primary service provider of this package, responsible for initializing core services, registering commands, and managing configurations.


2. RouteServiceProvider

The RouteServiceProvider revolutionizes route management by offering both file-based and attribute-based routing strategies, allowing developers to define routes declaratively or conventionally.


3. ArtisanServiceProvider

The ArtisanServiceProvider extends Laravel’s Artisan service provider to enhance the CLI experience with modular-focused commands.


4. MigrationServiceProvider

The MigrationServiceProvider extends Laravel’s migration workflows, enabling modular migration management.


5. EventServiceProvider

The EventServiceProvider enhances Laravel's event-handling capabilities by enabling dynamic event and listener discovery.


Key Benefits of Providers

  1. Centralized Configuration Management:

    • The DustServiceProvider ensures all package configurations are centralized and easily customizable.
  2. Enhanced Routing:

    • The RouteServiceProvider offers flexibility in route definition through attribute-based and file-based routing strategies.
  3. Streamlined CLI Experience:

    • The ArtisanServiceProvider simplifies scaffolding and repetitive tasks, improving developer productivity.
  4. Modular Database Operations:

    • The MigrationServiceProvider aligns migration management with the modular architecture.
  5. Dynamic Event Management:
    • The EventServiceProvider streamlines event and listener registration, adhering to the modular structure.

Support

The Support folder provides utility classes, traits, interfaces, and helpers to streamline functionality across the package. It enhances flexibility, modularity, and maintainability by encapsulating common functionalities and reusable patterns.


1. Traits

Traits encapsulate reusable methods that can be shared across multiple classes.


2. Interfaces

Interfaces define contracts for reusable functionalities.


3. Helpers

Utility functions to facilitate common operations within the package.


4. Logger

Provides a centralized logging mechanism with support for dynamic channels.


Key Benefits of the Support Folder

  1. Reusability:
    • Traits and interfaces promote code reuse, reducing duplication across the package.
  2. Utility:
    • Helper functions simplify and standardize operations related to modules and paths.
  3. Centralized Logging:
    • The Logger class offers a unified approach to handling logs with dynamic channel support.
  4. Enum Enhancements:
    • Traits like HasOptions and IsArrayable add extra functionality to enums, making them more flexible and useful.

Command Cheat Sheet

Below is a comprehensive cheat sheet for all the Artisan commands available in the Dust package. Each command supports modular scaffolding using the --module flag.

Command Description Example
make:story Creates a "story" structure, including controller, routes, and tests. php artisan make:story UserStory --module User --guard api
make:migration Generates a migration file in a specific module. php artisan make:migration create_users_table --module User
db:seed Runs a module-specific database seeder. php artisan db:seed --module User
make:cast Creates a custom cast class for a module. php artisan make:cast CustomCast --module User
make:command Generates a custom Artisan command for a module. php artisan make:command CustomCommand --module User
make:controller Scaffolds a controller with associated requests, responses, and services. php artisan make:controller UserController --module User --guard api
make:event Generates an event class within a module. php artisan make:event UserRegistered --module User
make:exception Creates a custom exception class in a module. php artisan make:exception CustomException --module User
make:factory Generates a factory class for a module. php artisan make:factory UserFactory --module User
make:job Creates a queued job class within a module. php artisan make:job ProcessUserRegistration --module User
make:listener Creates an event listener within a module. php artisan make:listener SendWelcomeEmail --module User
make:mail Generates a mail class for a module. php artisan make:mail WelcomeEmail --module User
make:middleware Creates middleware for a module. php artisan make:middleware AdminMiddleware --module User
make:model Scaffolds a model with associated factories, migrations, and policies. php artisan make:model User --module User
make:notification Generates a notification class scoped to a module. php artisan make:notification UserNotification --module User
make:observer Creates an observer class for a module. php artisan make:observer UserObserver --module User
make:policy Creates a policy class for a model. php artisan make:policy UserPolicy --module User --guard api
make:repository Generates a repository class for a module. php artisan make:repository UserRepository --module User
make:request Creates a form request class with guard support. php artisan make:request UserRequest --module User
make:resource Generates an API resource class within a module. php artisan make:resource UserResource --module User
make:response Creates a custom HTTP response class for a module. php artisan make:response CustomResponse --module User
make:seeder Scaffolds a seeder class within a module. php artisan make:seeder UserSeeder --module User
make:service Generates a service class for business logic encapsulation. php artisan make:service UserService --module User
make:test Creates a unit or feature test in a module. php artisan make:test UserTest --module User --unit

Key Notes:


Overview

Dust aims to simplify and enhance Laravel development through modularity, extensibility, and developer-centric tools. It provides a foundation for scalable, maintainable, and efficient applications.


All versions of dust with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1
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 cyberbugz/dust contains the following files

Loading the files please wait ....