In this episode, we're setting up a static 'Plans' page for our app where users can see the different subscription options available. First, we create a new controller and a route for the page, making sure it's easy to access from our navigation. We're keeping things straightforward: just a simple view (using a starter template from the GitHub repo) with options to switch between monthly and yearly pricing.
To make things look better and follow the existing design, we tweak the prices and also build a custom button component based on Laravel Breeze's style, but as a link – this way, users will eventually be able to click it to start the checkout process.
Next, instead of hardcoding all the plan details into our view, we show how to pull the plan info straight from our app's configuration. This means if you ever update your plans or their prices in your config file, your plans page updates automatically – no need to touch the view! We walk through dumping out the config, accessing the array of plans, and wiring everything up so it's easy to work with whether your plans are coming from config or (later on) from a database.
This episode is all about building a flexible, maintainable plans page you can improve later, and hooking it up visually so users can see their options and, soon, get started with a subscription.