承接 calebdw/larastan-livewire 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

calebdw/larastan-livewire

最新稳定版本:v2.3.0

Composer 安装命令:

composer require --dev calebdw/larastan-livewire

包简介

A Larastan / PHPStan extension for Livewire.

README 文档

README

Larastan Livewire

A Larastan / PHPStan extension for Laravel Livewire.

Test Results License Packagist Version Total Downloads

Install

composer require calebdw/larastan-livewire --dev

If you have the PHPStan extension installer installed then nothing more is needed, otherwise you will need to manually include the extension in the phpstan.neon(.dist) configuration file:

includes:
    - ./vendor/calebdw/larastan-livewire/extension.neon

Features

Computed Properties

Computed properties are properly resolved from methods that have the Computed attribute applied.

<?php

use Livewire\Attributes\Computed;
use Livewire\Component;

class ShowPost extends Component
{
    #[Computed]
    public function post()
    {
        return Post::find($this->postId);
    }
}

Getter Style

The older, "getter" style attributes are supported as well:

<?php

use Livewire\Component;

class ShowPost extends Component
{
    // Computed Property
    public function getPostProperty()
    {
        return Post::find($this->postId);
    }
}

Contributing

Thank you for considering contributing! You can read the contribution guide here.

License

Larastan-Livewire is open-sourced software licensed under the MIT license.

统计信息

  • 总下载量: 322.3k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 36
  • 点击次数: 1
  • 依赖项目数: 4
  • 推荐数: 0

GitHub 信息

  • Stars: 36
  • Watchers: 2
  • Forks: 2
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2023-12-22