PHPackages                             niefufeng/laravel-model-typescript - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. niefufeng/laravel-model-typescript

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

niefufeng/laravel-model-typescript
==================================

transform laravel models to typescript interfaces

0.1.0(2y ago)01.1k↓46.7%PHPPHP ^8.1

Since Apr 26Pushed 2y ago1 watchersCompare

[ Source](https://github.com/niefufeng/laravel-model-typescript)[ Packagist](https://packagist.org/packages/niefufeng/laravel-model-typescript)[ RSS](/packages/niefufeng-laravel-model-typescript/feed)WikiDiscussions master Synced today

READMEChangelog (1)Dependencies (6)Versions (3)Used By (0)

注意事项
----

[](#注意事项)

- php &gt;= 8.1
- 如果使用注释给 getter 设置返回值，返回 `Illuminate\\Database\\Eloquent\\Casts\\Attribute` 类，不能简写为 `Attribute`
- 如果使用 `Illuminate\\Database\\Eloquent\\Casts\\Attribute` 作为返回值，需要给 `get` 也写上返回值，比如 `Attribute::get(fn(): string => 'hello')`，否则将会生成 `any`

食用方式
----

[](#食用方式)

```
# install
composer require niefufeng/laravel-model-typescript --dev
# publish config files
php artisan vendor:publish --tag=model-typescript
# generate
php artisan model-typescript:generate
```

###  Health Score

24

—

LowBetter than 31% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity45

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~131 days

Total

2

Last Release

1033d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/3882254?v=4)[Outshine](/maintainers/niefufeng)[@niefufeng](https://github.com/niefufeng)

---

Top Contributors

[![niefufeng](https://avatars.githubusercontent.com/u/3882254?v=4)](https://github.com/niefufeng "niefufeng (3 commits)")

### Embed Badge

![Health badge](/badges/niefufeng-laravel-model-typescript/health.svg)

```
[![Health](https://phpackages.com/badges/niefufeng-laravel-model-typescript/health.svg)](https://phpackages.com/packages/niefufeng-laravel-model-typescript)
```

###  Alternatives

[illuminate/queue

The Illuminate Queue package.

21332.6M1.6k](/packages/illuminate-queue)[larastan/larastan

Larastan - Discover bugs in your code without running it. A phpstan/phpstan extension for Laravel

6.5k55.4M8.4k](/packages/larastan-larastan)[psalm/plugin-laravel

Psalm plugin for Laravel

3355.3M346](/packages/psalm-plugin-laravel)[laravel/ai

The official AI SDK for Laravel.

1.0k3.2M194](/packages/laravel-ai)[spatie/laravel-medialibrary

Associate files with Eloquent models

6.1k43.2M630](/packages/spatie-laravel-medialibrary)[mike-bronner/laravel-model-caching

Automatic caching for Eloquent models.

2.4k90.5k1](/packages/mike-bronner-laravel-model-caching)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
