#Bootcamp Livewire example - broken maybe?

1 messages · Page 1 of 1 (latest)

real fable
#

Has anyone here actually gotten the Livewire/Volt example on Bootcamp to work?

The "edit" portion is throwing an error for me. The link is here: https://bootcamp.laravel.com/livewire/editing-chirps

The error is "Cannot assign App\Models\Chirp to property Livewire\Volt\Component@anonymous::$chirp of type Chirp".

Thought I may have just typed something wrong, but I still get the error if I copy and paste the code from the guide. The template seems to be unable to recognize the "Chirp" model class.

Tagging with "laravel internals" because there's no livewire tag.

Together let's walk through building and deploying a modern Laravel application from scratch.

wraith garden
#

I guess you don't have use App\Models\Chirp in the file, so it would look for \Chirp, which is what the error is complaining about afaik

real fable
#

Nope, it's in there. I've even tried a direct reference like this: public ?App\Models\Chirp $chirp = null;

No dice, same error.

wraith garden
real fable
#

Nah, same error. Even this way:

#

I think there' s something up with the example. The error appears even when I copy and paste the code they are using.

#

That's what I meant to attach