In Joomla 3, I get module params with this code:
// Create the Application
$app = JFactory::getApplication('site');
$module = JModuleHelper::getModule('mod_dev');
$presetParams = new JRegistry($module->params);
$fontSize = $presetParams['fontSize'];
In Joomla 4, I start with this code:
// Boot the DI container.
$container = \Joomla\CMS\Factory::getContainer();
// Alias the session service key to the web session service.
$container->alias(\Joomla\Session\SessionInterface::class, 'session.web.site');
// Get the application.
$app = $container->get(\Joomla\CMS\Application\SiteApplication::class);
but
$module = JModuleHelper::getModule('mod_dev');
stopped working.
How can I access module params from external php file using the Joomla framework?