Skip to main content
CF

Writing Readable PHP

2h 40m 32s
English
Paid

Writing Readable PHP is a 23-lesson 2 hours 40 minutes self-paced course by Spatie. Learn how to write code that’s a joy to read for you, your co-workers, and future self.

Course facts

Lessons
23
Duration
2 hours 40 minutes
Language
English
Instructor
Spatie
Price
Premium

Learn how to write code that’s a joy to read for you, your co-workers, and future self. View high-quality videos on both clean coding and static analysis.

Are you...

  • Staring at your old code as if someone else wrote it?
  • Coding in a team without clean code habits?
  • Struggling with consistent naming?
  • Stop the madness! Let’s learn how to write readable PHP in this hands-on course.

Who teaches Writing Readable PHP? Spatie

Spatie thumbnail

Spatie is a Belgian web-development agency and one of the most respected names in the Laravel ecosystem — the author of more than 350 open-source PHP / Laravel packages (Laravel Permission, Laravel Backup, Laravel Translatable, Laravel Image Optimizer, and many others) that anchor a substantial portion of working Laravel codebases. Spatie's paid course material extends the same depth into long-form video.

The CourseFlix listing carries two Spatie courses: Writing Readable PHP (the code-quality / readability discipline applied to modern PHP) and Testing Laravel with PHPUnit (the testing workflow for production Laravel applications).

Material is paid and aimed at PHP / Laravel developers ready to take code quality and testing as serious professional disciplines. For broader content, see CourseFlix's Laravel and PHP category pages.

What lessons are included in Writing Readable PHP?

This is a demo lesson (10:00 remaining)

You can watch up to 10 minutes for free. Subscribe to unlock all 23 lessons in this course and access 10,000+ hours of premium content across all courses.

View Pricing
0:00
/
#1: Automatically formatting code
All Course Lessons (23)
#Lesson TitleDurationAccess
1
Automatically formatting code Demo
06:01
2
FORMATTING CODE USING GITHUB ACTIONS
03:28
3
Be Expressive
08:58
4
Be Consistent
06:53
5
Replace booleans in models with timestamps
03:53
6
Avoid using else
06:31
7
Refactoring complex conditionals
10:51
8
Make sure boolean parameters are readable
05:41
9
Using custom exceptions
11:22
10
Skip optional parameters by using named arguments
04:38
11
Replace if blocks with match
04:01
12
Trying out PHPStan for the first time
07:34
13
Class strings
05:38
14
Arrays and collections
11:06
15
Generics
10:21
16
Ignoring PHPStan issues
02:53
17
Use multiple routes files
05:41
18
Use custom Eloquent collections
07:10
19
Avoid strings where possible
06:00
20
Use Laravel's more descriptive methods if given
07:25
21
Leverage form requests
10:27
22
Use macros to clean up code
06:02
23
Embrace factories
07:58
Unlock unlimited learning

Get instant access to all 22 lessons in this course, plus thousands of other premium courses. One subscription, unlimited knowledge.

Learn more about subscription

Books

Read Book Writing Readable PHP

#TitleTypeOpen
1Book 1 —
2Book 2 —
3Book 3 —
4Book 4 —
5Book 5 —
6Book 6 —
7Book 7 —
8Book 8 —
9Book 9 —
10Book 10 —
11Book 11 —
12Book 12 —
13Book 13 —
14Book 14 —
15Book 15 —
16Book 16 —
17Book 17 —
18Book 18 —
19Book 19 —
20Book 20 —
21Book 21 —
22Book 22 —
23Book 23 —
24Book 24 —
25Book 25 —
26Book 26 —
27Book 27 —
28Book 28 —
29Book 29 —
30Book 30 —
31Book 31 —
32Book 32 —
33Book 33 —
34Book 34 —
35Book 35 —
36Book 36 —
37Book 37 —
38Book 38 —
39Book 39 —
40Book 40 —
41Book 41 —
42Book 42 —
43Book 43 —
44Book 44 —
45Book 45 —
46Book 46 —
47Book 47 —
48Book 48 —
49Book 49 —
50Book 50 —
51Book 51 —
52Book 52 —
53Book 53 —
54Book 54 —
55Book 55 —
56Book 56 —
57Book 57 —
58Book 58 —
59Book 59 —
60Book 60 —
61Book 61 —
62Book 62 —
63Book 63 —
64Book 64 —
65Book 65 —

What courses are similar to Writing Readable PHP?

More courses by Spatie

  • Testing Laravel with PHPUnit thumbnailUpdated 2y ago

    Testing Laravel with PHPUnit

    In this course, Brent will help you get started testing a Laravel application. He'll cover how to get started, how to test every functionality in Laravel, and g
    2h 42m5/5

Frequently asked questions

What are the prerequisites for enrolling in this course?
The course assumes a basic understanding of PHP and web development concepts. Familiarity with Laravel will be beneficial as some lessons involve Laravel-specific methods and features, such as Eloquent collections and form requests. No advanced expertise in PHP is required, but a general comfort with programming principles will help you get the most out of the content.
What will I build or achieve by the end of this course?
By the end of the course, you'll have improved your PHP code's readability and maintainability. You will learn to automatically format code, refactor complex conditionals, use custom exceptions, and leverage Laravel’s descriptive methods. The focus is on enhancing existing codebases to make them more expressive and consistent, rather than building a new application from scratch.
Who is the intended audience for this course?
This course is designed for PHP developers who want to improve the readability of their code. It's suitable for both junior developers looking to enhance their skills and experienced developers who wish to refine their coding practices. The course is particularly useful for those working in team environments where code readability and consistency are crucial.
What specific tools or platforms are covered in this course?
The course covers tools and techniques such as PHPStan for static analysis and GitHub Actions for automatic code formatting. It also explores Laravel-specific methods and features, such as custom Eloquent collections and form requests, which are used to improve code clarity and structure.
What topics are not covered in this course?
The course does not cover PHP basics or general programming concepts. It also does not delve into advanced PHP topics such as performance optimization, security practices, or full application development. The focus is strictly on writing clean, readable PHP code and leveraging specific tools for code analysis and formatting.
How much time should I expect to commit to this course?
Although the total runtime of the course videos is not specified, the course consists of 23 lessons. Students should expect to spend additional time practicing the techniques demonstrated, especially when applying them to their own codebases. A reasonable estimate would be several weeks of part-time study, depending on prior experience and learning pace.
How can skills from this course be applied in other areas or careers?
The skills learned in this course are applicable in any PHP development environment, enhancing code readability and maintainability. These practices can be beneficial in collaborative settings, improving team communication and reducing technical debt. The emphasis on clean coding and static analysis can be transferred to other programming languages and frameworks, broadening your skills in software craftsmanship.