Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

SymfonyCasts

Creating a Reusable (& Amazing) Symfony Bundle

via SymfonyCasts

Overview

Google, IBM & Meta Certificates – 40% Off
One Coursera Plus subscription covers most Professional Certificates on Coursera.
Unlock All Certificates

Want to share some code between projects, or maybe with the whole world? Let's do it! By creating a Symfony bundle! In this tutorial, we'll learn about bundles, their super-powers, how to add services & routes and the best-practices to create the best bundle possible:

  • Anatomy of a Bundle
  • Bundles vs Libraries
  • Building a bundle inside your app
  • DependencyExtensions to add Services
  • Complex Service configuration: Definitions & compiler passes
  • Allowing config via a Configuration class
  • Private services
  • Routing & other Configuration
  • Creating a Recipe
  • Registering your bundle with Packagist
  • Handling Releases
  • README!

Not only will you be able to create your own bundle, but we'll learn a lot along the way about how all bundles in the Symfony world work!

Syllabus

  • Bootstrapping the Bundle & Autoloading
  • Auto-Adding Services
  • Autowiring & Public/Private Services
  • All about the Bundle Extension Config System
  • Custom Extension Alias
  • Bundle Configuration Class
  • Allowing Entire Services to be Overridden
  • Extensibility with Interfaces & Aliases
  • Proper Bundle composer.json File
  • Testing the Bundle
  • Service Integration Test
  • Complex Config Test
  • Adding Routes & Controllers
  • Controller Functional Test
  • Dispatching Custom Events
  • Event Constants & @Event Docs
  • Plugin System with Tags
  • Tags, Compiler Passes & Other Nerdery
  • Publishing to Packagist
  • CI with Travis CI

Taught by

Ryan Weaver

Reviews

Start your review of Creating a Reusable (& Amazing) Symfony Bundle

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.