'clear']; protected $rules = [ 'key' => 'required|string', 'value' => 'required|string', 'is_build_time' => 'required|boolean', ]; public function mount() { $this->parameters = Route::current()->parameters(); } public function submit() { $this->validate(); $this->emitUp('submit', [ 'key' => $this->key, 'value' => $this->value, 'is_build_time' => $this->is_build_time, ]); } public function clear() { $this->key = ''; $this->value = ''; $this->is_build_time = false; } }