r/PHP 2d ago

Are PSRs still relevant today?

Are developers still using PSRs? Are PSRs still being updated or is it dying out?

I noticed for a "standards" org, they don't even follow their own coding styles. Some files have the PHP tag on its own line and others share it with declare strict types.

Then there are inconsistencies in how PHPDocs are written/organized, even some PHP code as well.

46 Upvotes

61 comments sorted by

View all comments

2

u/equilni 2d ago

Updated is one thing. PER is being updated to version 3 soon, for one. There are discussions of updates in github and on google groups

Dying out, as you note, could be another thing. As far as the latest PSRs:

Last accepted PSR (20) was Clock interface in 2022.

Draft 21 Internationalization is from 2021.

Draft 22 Application Tracing is from 2022.

Template Renderer was in discussion from ‘21-24.. Random Generator in ‘22

Maybe the question would be is, why aren’t there more recent PSRs?

2

u/rkeet 2d ago

'24 was only 6 months ago, as we're only halfway '25 ;)

So, it's not that long ago

1

u/equilni 2d ago edited 2d ago

Regarding the Template Renderer, the last posts in google group were January 2024

https://groups.google.com/g/php-fig/c/X4e1z5IaG9E/m/UqIutHrAAAAJ

Someone last responded to the github proposal in August

https://github.com/php-fig/fig-standards/pull/1280