maksi/laravel-idea-type-hinting

为Eloquent模型提供更好的类型提示

1.0.1 2018-05-01 16:40 UTC

This package is auto-updated.

Last update: 2024-09-06 23:36:30 UTC


README

这是一个用于更好类型提示的包

用法

  1. 您可以扩展Maksi\TypeHinting\Database\Eloquent\Model模型。
  2. 您可以直接在模型中使用特性:Maksi\TypeHinting\Eloquent\Concerns\ModelAnnotations.phpMaksi\TypeHinting\Eloquent\Concerns\ModelStaticAnnotations.php

在执行model extendingtraits usages后,Eloquent构建器的方 法将在您的模型上类型提示

  • whereKey
  • whereKeyNot
  • where
  • find
  • findMany
  • findOrFail
  • findOrNew
  • firstOrNew
  • firstOrCreate
  • updateOrCreate
  • firstOrFail
  • firstOr
  • create
  • forceCreate
  • update
  • paginate

https://packagist.org.cn/packages/maksi/laravel-idea-type-hinting

问题

如果您有改进的建议,请为此项目创建问题/PR