Symfony Complementary modules
Good to know
Objectives of the training
To make the participants acquire the knowledge of the mechanisms of the framework of the different module(s) chosen.
Description
The content is regularly updated to always cover the latest version of Symfony and the modules' components.
The course is presented in the form of a web application project realized by each participant. Practical work takes place throughout the course, which gradually leads participants to correct their mistakes.
The emphasis is on good practices.
Educational material provided
The trainer will distribute the training materials in electronic format at the end of the training.
In addition, the work will result in the creation of a step-by-step versioned web application. Each participant is invited to keep the code of the training project on his machine, which he will have written himself with the help of the trainer, because this code can be used as a technical base for future projects.
Pre-requisites
In order to fully benefit from the training, participants must have previous professional experience in the following areas
- object-oriented PHP development
- use of a relational database
- specific prerequisites to be determined according to the chosen module(s)
Participants should have a computer with admin rights, allowing them to do the exercises proposed throughout the training, with a LAMP environment including preferably the following elements
- An internet connection allowing the installation of PHP extensions and packages from packagist and working with ease (if training outside our premises)
- A mastered IDE (PHPStorm, SublimeText, VSCode, ...)
- A UNIX shell
- A currently supported version of PHP (https://www.php.net/supported-versions.php)
- Git installed (useful for composer dependencies)
- One MySql/MariaDB server per person
- Administrator rights on the machine
It is advisable to allow participants to use a text editor they feel most comfortable with in order to concentrate on the training. **It is not necessary to install Symfony, this part will be covered during the training.
More generally, if the training takes place on the customer's premises, it is required that a room allowing to welcome all the participants as well as the trainer be reserved during the whole training period. training. A presentation screen (projector or large flat screen TV) must be present in this room to allow participants to view the trainer's screen. A flip chart or erasable board erasable board and an internet connection would also be appreciated.
Modules
Symfony forms & validation - 12H
Building Forms
Simple Type
Collection Type
Custom Type
Rendering
Templating
Passing Options to forms
Validating form input
Form Events
Data mapper
Data transformer
Form type extension
CSRF Protection
Hexagonal architecture - 21H
Why ?
Domain / Application / Infrastructure
Deptrack
SOLID Principles
Update Symfony project architecture
How to deal with doctrine and entities
Take advantage of Services aliases
Examples with repositories
How to deal with the security component
The command bus pattern
Extending the domain with events
Mailer - 2H
Configuration
Transport
Creating and Sending messages
Email addresses
Message Headers
Message Content
Twig and CSS content
Embedding Images
Embedding CSS
Mailer Events
Draft Emails
Development & Debbuging
Disabling delivery
Always send to the same Address
How to test email delivery
TWIG Templating - 4H
Rendering a template
In a controller
In a service
Rendering a Template Directly from a Route
Manage assets
Webpack encore
The app variable
Debugging template
The Dump Twig Utilities
Linting twig template
Reusing template contents
Template inheritance and layout
Including Templates
Embedding Controllers
Twig extensions
Common extensions
Create custom extensions
REST API with Sf - 14H
Request / Response
JSON Response
Status codes
Routes naming strategy
Common Headers to take care of
Documentation with Open API
JSON Schema Validation
Serialization
Filter
Sort
Paginate
Trade-offs with meta-libraries
EasyAdminBundle
API Platform
Upgrade Symfony versions - 2H
Observations about the project
Setup a reproducible environment
Audit of the tests stack
Cleanup the code
State of dependencies
Create a roadmap
PHP Stan
Setup a dependencies update workflow
Iterate over updates
Common traps that can lock an update
Define a long term strategy regularly update dependencies
Doctrine - 7H
Migrations
Performing a migration / Reverting to an old migration
Doctrine associations / Relationships
Doctrine associations / Relations
Fixtures
Objects queries
Expression builder
Problème N+1
Test a Doctrine repository
Test a Doctrine repository
Configuration
Object validation
Doctrine extensions
Automatic retrieval of objects (ParamConverter)
Custom type
Security - 14H
The User
Hierarchy of roles
User Provider
The Firewall
Authenticators
Login form
Json login
Basic Http
Custom authenticators (Http cookie only)
JWT
Encode with a passphrase
Encode with RSA key pair
Encode password
Automatically encode a user's password
Migrate a user's password to another encryption method
Security events
Logout
Access control
Messenger - 21H
Creating a message manager
Sending messages
Transport configuration
Synchronous / Asynchronous
Routing messages to a transport
Message consumption
Attempts and failures
Middlewares
Extending Messenger
Handling multiple buses
Mercure - 7h
Installation & Configuration
Basic Usages (Publishing / Subscribing)
Debugging
Discovery
Authorization
Testing
Async dispatching
Console - 4h
Behat with friends-of-behat/symfony-extension - 7h
Good practices to keep the project up-to-date - 2h
Dockerize a Symfony project - 4h
GraphQL API with Symfony - 7h