by Devin Yang
(This article was automatically translated.)

Published - 2 years ago ( Updated - 2 years ago )

Before starting your Livewire journey,
Here are three basic considerations about public properties:

* 100009*1. The property name cannot conflict with the property name reserved for Livewire (for example, $rules or $message)

2. The data stored in the public properties (public properties), for Front-end JavaScript is visible.
Therefore, you should not store sensitive data in it.

3. Attributes can only be JavaScript-friendly data types (string, integer, array, boolean), or one of the following PHP types: Stringable, Collection, DateTime, Model, EloquentCollection.

Tags: laravel livewire

Devin Yang

Feel free to ask me, if you don't get it.:)

No Comment

Post your comment

Login is required to leave comments

Similar Stories


dlaravel

Description of .env.example file on D-Laravel

This article explains about the .env settings on D-Laravel MYSQL_ROOT_PASSWORD=secret LARAVEL_INSTALLER='container' DOCKER_SERVICES='docker-compose.yml service/redis.yml'

docker,laravel

[D-Laravel]./console node

When developing Laravel, sometimes we need to install nodejs packages through npm, but Node in our system is not new enough. It may be impossible to upgrade due to some factors, such as running an old version of nodejs program, etc. In fact, we can use docker through simple commands, so that we can use the latest version of node image to mount the /sites folder on the host side. In this way, we can execute the new version of the npm command at any time.

laravel docker

About D-Laravel's project mode

If you are a new user, I suggest you use my latest environment phpenv instead. https://github.com/DevinY/phpenv