Upgrade to PRO for Only $50/Year—Limited-Time Offer! 🔥
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
I shall define this only once
Search
Freek Van der Herten
September 14, 2022
Programming
0
450
I shall define this only once
Freek Van der Herten
September 14, 2022
Tweet
Share
More Decks by Freek Van der Herten
See All by Freek Van der Herten
Uncharted packages (ode aan de code)
freekmurze
0
40
Uncharted packages (Laravel Live Denmark)
freekmurze
0
230
An Introduction to Snapshot testing
freekmurze
0
520
Event Sourcing In Laravel
freekmurze
0
270
Building a realtime dashboard with Laravel Livewire (PHPKonf)
freekmurze
0
840
A tour behind the scenes of Oh Dear (PHP Benelux)
freekmurze
2
880
A practical look at multitenancy in Laravel
freekmurze
1
380
A practical look at multitenancy in Laravel (Laracon US)
freekmurze
0
760
Highlights Flare codebase (Laracon online)
freekmurze
0
550
Other Decks in Programming
See All in Programming
Pythonではじめるオープンデータ分析〜書籍の紹介と書籍で紹介しきれなかった事例の紹介〜
welliving
2
510
gunshi
kazupon
1
110
AI Agent Tool のためのバックエンドアーキテクチャを考える #encraft
izumin5210
2
650
GISエンジニアから見たLINKSデータ
nokonoko1203
0
180
안드로이드 9년차 개발자, 프론트엔드 주니어로 커리어 리셋하기
maryang
1
130
Canon EOS R50 V と R5 Mark II 購入でみえてきた最近のデジイチ VR180 事情、そして VR180 静止画に活路を見出すまで
karad
0
130
Python札幌 LT資料
t3tra
6
1k
AIエンジニアリングのご紹介 / Introduction to AI Engineering
rkaga
8
3.2k
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
270
Tinkerbellから学ぶ、Podで DHCPをリッスンする手法
tomokon
0
140
C-Shared Buildで突破するAI Agent バックテストの壁
po3rin
0
410
宅宅自以為的浪漫:跟 AI 一起為自己辦的研討會寫一個售票系統
eddie
0
520
Featured
See All Featured
StorybookのUI Testing Handbookを読んだ
zakiyama
31
6.5k
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.5k
How To Stay Up To Date on Web Technology
chriscoyier
791
250k
What Being in a Rock Band Can Teach Us About Real World SEO
427marketing
0
150
Bioeconomy Workshop: Dr. Julius Ecuru, Opportunities for a Bioeconomy in West Africa
akademiya2063
PRO
0
31
Java REST API Framework Comparison - PWX 2021
mraible
34
9k
It's Worth the Effort
3n
187
29k
Agile Actions for Facilitating Distributed Teams - ADO2019
mkilby
0
92
Ruling the World: When Life Gets Gamed
codingconduct
0
94
The Hidden Cost of Media on the Web [PixelPalooza 2025]
tammyeverts
2
120
Site-Speed That Sticks
csswizardry
13
1k
Claude Code のすすめ
schroneko
65
200k
Transcript
I shall say define this only once
About me Freek Van der Herten Developer at SPATIE @freekmurze
freek.dev mailcoach.app ohdear.app fl areapp.io
Open source ± 300 packages on Packagist ± 360 000
000 downloads total ± 20 000 000 downloads a month
spatie.be/open-source
spatie.be/open-source/postcards
Let’s talk about Laravel Data
At Spatie Big projects Complex data, lots of properties and
relations A lot data structures de fi ned multiple times for di ff erent purposes Form requests, API resources, TypeScript de fi nitions
Laravel Data An easy to use Laravel package Create powerful
data objects A single de fi nition that can be used for multiple purposes Created by Ruben Van Assche 250K downloads
This talk A simple example Real world usage in Flare
Let’s code
In closing
Laravel Data Rich data objects De fi ne a data
structure only once Can replace API resources, Form Requests, … Generating TypeScript de fi nitions
Laravel Data Optional properties Lazy loading of properties Create data
from incoming requests, JSON and objects In fi nitely con fi gurable … and a whole lot more
spatie.be/docs/laravel-data
Laravel Data For everything For only small parts Don’t just
discard the Laravel defaults Do what is best for your team and project
One more thing
Laracon Promo 20% discount on all spatie products, no coupon
needed spatie.be/products Products: Ray, Mailcoach, Laravel Comments, MediaLibrary Pro Courses: Testing Laravel, Laravel Package Training, Laravel Beyond Crud, Writing Readable Laravel, Laravel Event Sourcing
Thank you! freek.dev mailcoach.app spatie.be ohdear.app fl areapp.io