Implement ticket selection with Stimulus controller and improve code documentation
- Add ticket selection functionality to event show page using Stimulus - Create ticket_selection_controller.js for handling ticket quantity changes - Update ticket card component and event show view to work with Stimulus - Add comprehensive comments to all JavaScript files for better maintainability - Remove dependent: :destroy from event ticket_types association
This commit is contained in:
@@ -1,12 +1,19 @@
|
||||
// Main Stimulus application controller
|
||||
// Initializes the Stimulus framework and makes it available globally
|
||||
import { Application } from "@hotwired/stimulus";
|
||||
|
||||
// Create and start the Stimulus application
|
||||
const application = Application.start();
|
||||
|
||||
// Configure Stimulus development experience
|
||||
// Set to false in production to avoid unnecessary logging
|
||||
application.debug = false;
|
||||
|
||||
// Make Stimulus globally available for debugging purposes
|
||||
window.Stimulus = application;
|
||||
|
||||
// import Alpine from 'alpinejs';
|
||||
// Configure Alpine js (commented out as it's not currently used)
|
||||
// import Alpine from "alpinejs";
|
||||
// window.Alpine = Alpine;
|
||||
// Alpine.start();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user