I’ve just purchased and downloaded the soil plugin, and tried installing it on the Sage 10 theme. I can install and activate it without issue, but whether the plugin is activated or not, I do not see any improvements in the markup. For example I still see script tags in the head and early in the body despite having ‘js-to-footer’ enabled. I have do not see any google analytics injected, nor am I prevented from accessing the REST api by simply firing a get request to http://sage.test/wp-json/wp/v2/posts
I have added the following to the themes/sage/app/setup.php:
add_action('after_setup_theme', function () {
/**
* Enable features from the Soil plugin if activated.
*/
add_theme_support('soil', [
'clean-up', // Cleaner WordPress markup
'disable-rest-api', // Disable REST API
'disable-asset-versioning', // Remove asset versioning
'disable-trackbacks', // Disable trackbacks
'google-analytics' => 'UA-XXXXX-Y', // Google Analytics
'js-to-footer', // Move JS to footer
'nav-walker', // Clean up nav menu markup
'nice-search', // Redirect /?s=query to /search/query
'relative-urls', // Convert absolute URLs to relative URLs
]);
});
Am I misunderstanding something in the installation and setup process?