blob: 6f53d84bb0b958d750b81581d296d95a34f60dab (
plain)
1
2
3
4
5
6
7
8
9
|
// Load all the controllers within this directory and all subdirectories.
// Controller files must be named *_controller.js.
import { Application } from "stimulus"
import { definitionsFromContext } from "stimulus/webpack-helpers"
const application = Application.start()
const context = require.context("controllers", true, /_controller\.js$/)
application.load(definitionsFromContext(context))
|