{"adoption": {"forks": 60, "observed_at": "2026-08-28T04:03:32.782699+00:00", "stars": 1090}, "canonical_url": "https://ross.abutalabs.com/products/laravel-view-models", "card": {"archived": false, "artifact_type": "library", "description": "View models in Laravel", "domain": ["web-development", "backend", "developer-tools"], "enriched": true, "function": ["templating", "middleware"], "health_score": 88, "homepage": "https://spatie.be/open-source", "language": "PHP", "license": "MIT", "license_family": "permissive", "maturity": "stable", "member_repos": ["spatie/laravel-view-models"], "name": "spatie/laravel-view-models", "platform": ["php"], "pushed_at": "2026-06-02T06:36:56+00:00", "repo": "spatie/laravel-view-models", "stars": 1090, "tags": ["laravel", "view-models", "mvc", "spatie", "blade"], "topics": ["laravel", "php", "view", "models"], "urls": [], "use_cases": ["move view preparation logic out of fat Laravel controllers", "pass structured data objects to Blade views", "organize complex view data like categories and URLs in one class", "replace or complement Laravel view composers", "keep create/edit form controllers clean"], "what_it_is": "A Laravel package by Spatie that provides view models: classes that prepare and transform data for views, keeping controllers slim. It offers a simple ViewModel base class to encapsulate view-specific logic.", "when_to_avoid": ["you don't use Laravel or PHP", "your views are simple and controllers are already thin", "you rely on Blade components or Livewire for view logic"], "when_to_choose": ["you use Laravel and controllers are doing heavy data preparation for views", "you want an alternative to view composers with explicit per-action data", "you prefer object-oriented view data over passing loose arrays"]}, "data_as_of": "2026-08-30T08:39:29.467469+00:00", "members": [{"path": "/products/laravel-view-models", "repo": "spatie/laravel-view-models", "role": "main", "score": 72}], "provenance": {"archived": {"kind": "observed", "observed_at": "2026-08-28T04:03:32.782699+00:00", "source": "github"}, "artifact_type": {"confidence": null, "enriched_at": "2026-08-30T06:49:14.199176+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "963936e3f22368b4454e3d4a4e6436dc71e974c5f243ae56cacb0e0f89b4af26", "fetched_at": "2026-08-28T04:03:32.782699+00:00", "kind": "readme", "missing": false, "url": "https://github.com/spatie/laravel-view-models"}, {"content_hash": "6ed5abf6953512cdad6eb920fa55f5f745aeaf5fe3aba342a259c63597911107", "fetched_at": "2026-08-29T12:51:28.003481+00:00", "kind": "homepage", "missing": false, "url": "https://spatie.be/open-source"}, {"content_hash": "08e024d86d95c41664c322c41f72dd4ffbdb77bdb2593df69b7da9257528b182", "fetched_at": "2026-08-29T12:51:28.007327+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/docs"}, {"content_hash": "d3cb88e4b34c8f48a454735b613f7e1bc733398952e9c21cf4046bbeaa923d24", "fetched_at": "2026-08-29T12:51:28.009938+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/about-us"}], "taxonomy_version": 1}, "description": {"kind": "observed", "observed_at": "2026-08-28T04:03:32.782699+00:00", "source": "github"}, "domain": {"confidence": null, "enriched_at": "2026-08-30T06:49:14.199176+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "963936e3f22368b4454e3d4a4e6436dc71e974c5f243ae56cacb0e0f89b4af26", "fetched_at": "2026-08-28T04:03:32.782699+00:00", "kind": "readme", "missing": false, "url": "https://github.com/spatie/laravel-view-models"}, {"content_hash": "6ed5abf6953512cdad6eb920fa55f5f745aeaf5fe3aba342a259c63597911107", "fetched_at": "2026-08-29T12:51:28.003481+00:00", "kind": "homepage", "missing": false, "url": "https://spatie.be/open-source"}, {"content_hash": "08e024d86d95c41664c322c41f72dd4ffbdb77bdb2593df69b7da9257528b182", "fetched_at": "2026-08-29T12:51:28.007327+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/docs"}, {"content_hash": "d3cb88e4b34c8f48a454735b613f7e1bc733398952e9c21cf4046bbeaa923d24", "fetched_at": "2026-08-29T12:51:28.009938+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/about-us"}], "taxonomy_version": 1}, "enriched": {"inputs": [], "kind": "computed", "method": "enrichment_status"}, "function": {"confidence": null, "enriched_at": "2026-08-30T06:49:14.199176+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "963936e3f22368b4454e3d4a4e6436dc71e974c5f243ae56cacb0e0f89b4af26", "fetched_at": "2026-08-28T04:03:32.782699+00:00", "kind": "readme", "missing": false, "url": "https://github.com/spatie/laravel-view-models"}, {"content_hash": "6ed5abf6953512cdad6eb920fa55f5f745aeaf5fe3aba342a259c63597911107", "fetched_at": "2026-08-29T12:51:28.003481+00:00", "kind": "homepage", "missing": false, "url": "https://spatie.be/open-source"}, {"content_hash": "08e024d86d95c41664c322c41f72dd4ffbdb77bdb2593df69b7da9257528b182", "fetched_at": "2026-08-29T12:51:28.007327+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/docs"}, {"content_hash": "d3cb88e4b34c8f48a454735b613f7e1bc733398952e9c21cf4046bbeaa923d24", "fetched_at": "2026-08-29T12:51:28.009938+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/about-us"}], "taxonomy_version": 1}, "health_score": {"inputs": ["days_since_push", "days_since_release", "archived"], "kind": "computed", "method": "health_v1"}, "homepage": {"kind": "observed", "observed_at": "2026-08-28T04:03:32.782699+00:00", "source": "github"}, "language": {"kind": "observed", "observed_at": "2026-08-28T04:03:32.782699+00:00", "source": "github"}, "license": {"kind": "observed", "observed_at": "2026-08-28T04:03:32.782699+00:00", "source": "github"}, "license_family": {"inputs": ["license"], "kind": "computed", "method": "license_family"}, "maturity": {"confidence": null, "enriched_at": "2026-08-30T06:49:14.199176+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "963936e3f22368b4454e3d4a4e6436dc71e974c5f243ae56cacb0e0f89b4af26", "fetched_at": "2026-08-28T04:03:32.782699+00:00", "kind": "readme", "missing": false, "url": "https://github.com/spatie/laravel-view-models"}, {"content_hash": "6ed5abf6953512cdad6eb920fa55f5f745aeaf5fe3aba342a259c63597911107", "fetched_at": "2026-08-29T12:51:28.003481+00:00", "kind": "homepage", "missing": false, "url": "https://spatie.be/open-source"}, {"content_hash": "08e024d86d95c41664c322c41f72dd4ffbdb77bdb2593df69b7da9257528b182", "fetched_at": "2026-08-29T12:51:28.007327+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/docs"}, {"content_hash": "d3cb88e4b34c8f48a454735b613f7e1bc733398952e9c21cf4046bbeaa923d24", "fetched_at": "2026-08-29T12:51:28.009938+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/about-us"}], "taxonomy_version": 1}, "member_repos": {"kind": "observed", "observed_at": "2026-08-28T04:03:32.782699+00:00", "source": "github"}, "name": {"kind": "observed", "observed_at": "2026-08-28T04:03:32.782699+00:00", "source": "github"}, "platform": {"confidence": null, "enriched_at": "2026-08-30T06:49:14.199176+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "963936e3f22368b4454e3d4a4e6436dc71e974c5f243ae56cacb0e0f89b4af26", "fetched_at": "2026-08-28T04:03:32.782699+00:00", "kind": "readme", "missing": false, "url": "https://github.com/spatie/laravel-view-models"}, {"content_hash": "6ed5abf6953512cdad6eb920fa55f5f745aeaf5fe3aba342a259c63597911107", "fetched_at": "2026-08-29T12:51:28.003481+00:00", "kind": "homepage", "missing": false, "url": "https://spatie.be/open-source"}, {"content_hash": "08e024d86d95c41664c322c41f72dd4ffbdb77bdb2593df69b7da9257528b182", "fetched_at": "2026-08-29T12:51:28.007327+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/docs"}, {"content_hash": "d3cb88e4b34c8f48a454735b613f7e1bc733398952e9c21cf4046bbeaa923d24", "fetched_at": "2026-08-29T12:51:28.009938+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/about-us"}], "taxonomy_version": 1}, "pushed_at": {"kind": "observed", "observed_at": "2026-08-28T04:03:32.782699+00:00", "source": "github"}, "repo": {"kind": "observed", "observed_at": "2026-08-28T04:03:32.782699+00:00", "source": "github"}, "stars": {"kind": "observed", "observed_at": "2026-08-28T04:03:32.782699+00:00", "source": "github"}, "tags": {"confidence": null, "enriched_at": "2026-08-30T06:49:14.199176+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "963936e3f22368b4454e3d4a4e6436dc71e974c5f243ae56cacb0e0f89b4af26", "fetched_at": "2026-08-28T04:03:32.782699+00:00", "kind": "readme", "missing": false, "url": "https://github.com/spatie/laravel-view-models"}, {"content_hash": "6ed5abf6953512cdad6eb920fa55f5f745aeaf5fe3aba342a259c63597911107", "fetched_at": "2026-08-29T12:51:28.003481+00:00", "kind": "homepage", "missing": false, "url": "https://spatie.be/open-source"}, {"content_hash": "08e024d86d95c41664c322c41f72dd4ffbdb77bdb2593df69b7da9257528b182", "fetched_at": "2026-08-29T12:51:28.007327+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/docs"}, {"content_hash": "d3cb88e4b34c8f48a454735b613f7e1bc733398952e9c21cf4046bbeaa923d24", "fetched_at": "2026-08-29T12:51:28.009938+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/about-us"}], "taxonomy_version": 1}, "topics": {"kind": "observed", "observed_at": "2026-08-28T04:03:32.782699+00:00", "source": "github"}, "urls": {"kind": "observed", "observed_at": "2026-08-28T04:03:32.782699+00:00", "source": "github"}, "use_cases": {"confidence": null, "enriched_at": "2026-08-30T06:49:14.199176+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "963936e3f22368b4454e3d4a4e6436dc71e974c5f243ae56cacb0e0f89b4af26", "fetched_at": "2026-08-28T04:03:32.782699+00:00", "kind": "readme", "missing": false, "url": "https://github.com/spatie/laravel-view-models"}, {"content_hash": "6ed5abf6953512cdad6eb920fa55f5f745aeaf5fe3aba342a259c63597911107", "fetched_at": "2026-08-29T12:51:28.003481+00:00", "kind": "homepage", "missing": false, "url": "https://spatie.be/open-source"}, {"content_hash": "08e024d86d95c41664c322c41f72dd4ffbdb77bdb2593df69b7da9257528b182", "fetched_at": "2026-08-29T12:51:28.007327+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/docs"}, {"content_hash": "d3cb88e4b34c8f48a454735b613f7e1bc733398952e9c21cf4046bbeaa923d24", "fetched_at": "2026-08-29T12:51:28.009938+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/about-us"}], "taxonomy_version": 1}, "what_it_is": {"confidence": null, "enriched_at": "2026-08-30T06:49:14.199176+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "963936e3f22368b4454e3d4a4e6436dc71e974c5f243ae56cacb0e0f89b4af26", "fetched_at": "2026-08-28T04:03:32.782699+00:00", "kind": "readme", "missing": false, "url": "https://github.com/spatie/laravel-view-models"}, {"content_hash": "6ed5abf6953512cdad6eb920fa55f5f745aeaf5fe3aba342a259c63597911107", "fetched_at": "2026-08-29T12:51:28.003481+00:00", "kind": "homepage", "missing": false, "url": "https://spatie.be/open-source"}, {"content_hash": "08e024d86d95c41664c322c41f72dd4ffbdb77bdb2593df69b7da9257528b182", "fetched_at": "2026-08-29T12:51:28.007327+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/docs"}, {"content_hash": "d3cb88e4b34c8f48a454735b613f7e1bc733398952e9c21cf4046bbeaa923d24", "fetched_at": "2026-08-29T12:51:28.009938+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/about-us"}], "taxonomy_version": 1}, "when_to_avoid": {"confidence": null, "enriched_at": "2026-08-30T06:49:14.199176+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "963936e3f22368b4454e3d4a4e6436dc71e974c5f243ae56cacb0e0f89b4af26", "fetched_at": "2026-08-28T04:03:32.782699+00:00", "kind": "readme", "missing": false, "url": "https://github.com/spatie/laravel-view-models"}, {"content_hash": "6ed5abf6953512cdad6eb920fa55f5f745aeaf5fe3aba342a259c63597911107", "fetched_at": "2026-08-29T12:51:28.003481+00:00", "kind": "homepage", "missing": false, "url": "https://spatie.be/open-source"}, {"content_hash": "08e024d86d95c41664c322c41f72dd4ffbdb77bdb2593df69b7da9257528b182", "fetched_at": "2026-08-29T12:51:28.007327+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/docs"}, {"content_hash": "d3cb88e4b34c8f48a454735b613f7e1bc733398952e9c21cf4046bbeaa923d24", "fetched_at": "2026-08-29T12:51:28.009938+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/about-us"}], "taxonomy_version": 1}, "when_to_choose": {"confidence": null, "enriched_at": "2026-08-30T06:49:14.199176+00:00", "kind": "inferred", "prompt_version": 1, "sources": [{"content_hash": "963936e3f22368b4454e3d4a4e6436dc71e974c5f243ae56cacb0e0f89b4af26", "fetched_at": "2026-08-28T04:03:32.782699+00:00", "kind": "readme", "missing": false, "url": "https://github.com/spatie/laravel-view-models"}, {"content_hash": "6ed5abf6953512cdad6eb920fa55f5f745aeaf5fe3aba342a259c63597911107", "fetched_at": "2026-08-29T12:51:28.003481+00:00", "kind": "homepage", "missing": false, "url": "https://spatie.be/open-source"}, {"content_hash": "08e024d86d95c41664c322c41f72dd4ffbdb77bdb2593df69b7da9257528b182", "fetched_at": "2026-08-29T12:51:28.007327+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/docs"}, {"content_hash": "d3cb88e4b34c8f48a454735b613f7e1bc733398952e9c21cf4046bbeaa923d24", "fetched_at": "2026-08-29T12:51:28.009938+00:00", "kind": "site_page", "missing": false, "url": "https://spatie.be/about-us"}], "taxonomy_version": 1}}, "score": {"components": {"activity": 85, "longevity": 100, "rhythm": 39}, "computed_at": "2026-09-03T02:20:16.233290+00:00", "flags": [], "formula": "round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)", "inputs": {"age_days": 2917, "days_push": 92, "days_rel": 193, "gap_med": 372, "n_releases_24m": 2}, "score": 72, "version": 2}, "staleness": {"enrichment_outdated": false, "low_confidence": false, "scrape_days": 9, "stale_scrape": false}}