簡體   English   中英

面對404,找不到路由。 Laravel 火線

[英]Facing 404, The route could not be found. Laravel Livewire

我面臨 404,找不到路由public/livewire/message/software-category

我將 Laravel 9 與 livewire 一起使用,並且我的組件已完美加載,但是當我嘗試更新組件的任何屬性值時,它返回404 not found

這是我的.env

APP_URL=https://fyp.devndesigns.com/
ASSET_URL=https://fyp.devndesigns.com/public

這是我的 config/livewire.php,我在其中更改了 asset_url 但它不起作用。

<?php

return [

    /*
    |--------------------------------------------------------------------------
    | Livewire Assets URL
    |--------------------------------------------------------------------------
    |
    | This value sets the path to Livewire JavaScript assets, for cases where
    | your app's domain root is not the correct path. By default, Livewire
    | will load its JavaScript assets from the app's "relative root".
    |
    | Examples: "/assets", "myurl.com/app".
    |
    */

    'asset_url' => env('ASSET_URL'),

    /*
    |--------------------------------------------------------------------------
    | Livewire App URL
    |--------------------------------------------------------------------------
    |
    | This value should be used if livewire assets are served from CDN.
    | Livewire will communicate with an app through this url.
    |
    | Examples: "https://my-app.com", "myurl.com/app".
    |
    */

    'app_url' => null,

.env更改為:

APP_URL=https://fyp.devndesigns.com
ASSET_URL=https://fyp.devndesigns.com

config/livewire.php

'asset_url' => env('ASSET_URL', null),

'app_url' => env('APP_URL', 'http://localhost'),

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM