Upgrade Last updated: 2025-01-21

Updating Dash to the Latest Version

If you have used older versions of Dash and want to enjoy the experience of using it via Composer, follow these steps to install the new version and perform the necessary updates:


Step 1: Remove Old References

From your main project's composer.json, remove the following line:

"phpanonymous/dash": "*",

Also, remove the following block:

"repositories": [
    {
        "type": "path",
        "url": "dash"
    }
],

Step 2: Update dash.php Configuration

Go to the dash.php file in the config folder. Replace the following lines:

/**
 * Don't change anything here; these are default values for Dash.
 * @param functions
 */
'THEME_PATH'            => base_path('dash/src/resources/views'),
'LOCALE_PATH'           => base_path('dash/src/resources/lang'),
'DATATABLE_LOCALE_PATH' => base_path('dash/src/resources/lang'),
'ROUTE_PATH'            => base_path('dash/src/routes/routelist.php'),

With the following updated paths:

/**
 * Don't change anything here; these are default values for Dash.
 * @param functions
 */
'THEME_PATH'            => base_path('vendor/phpanonymous/dash/src/resources/views'),
'LOCALE_PATH'           => base_path('vendor/phpanonymous/dash/src/resources/lang'),
'DATATABLE_LOCALE_PATH' => base_path('vendor/phpanonymous/dash/src/resources/lang'),
'ROUTE_PATH'            => base_path('vendor/phpanonymous/dash/src/routes/routelist.php'),

Step 3: Install Dash via Composer

Run the following command to install Dash via Composer:

composer require phpanonymous/dash

Step 4: Run the Update Command

After installation, execute the following command to update Dash:

php artisan dash:update

Step 5: You're Done!

Congratulations! You have successfully updated Dash to the latest version using Composer.


Notes

  • Ensure your Laravel project meets the requirements for the new version of Dash.
  • If you encounter any issues, refer to the official documentation for troubleshooting.