In scenario where you have existing website and want to partially rebuild it and migrate to tailwind we are offering option to enable Winden only selected pages, post types, taxonomies or what ever you desire.
<?php
/**
* Call CDN in Particular page.
*/
function dp_call_winden(){
if (is_page(['blog', 'about-us', 'contact-us']) || if_front_page() ) {
add_action('wp_footer', 'dp_footer_cdn');
}
}
function dp_footer_cdn(){
$winden_instance = apply_filters('f!Wakaloka\\Winden::get_instance', null);
$winden_instance->runtime->enqueue_cdn(); // print / echo the cdn
}
add_action('template_redirect', 'dp_call_winden');
/**
* Disable auto CDN load.
*/
function dp_init()
{
if (!is_admin()) {
add_filter('f!Wakaloka\\Winden\\Core\\Runtime::is_inside_builder', fn($is) => true, 5);
}
}
add_action('init', 'dp_init', 5);
?>
Replace WP Condition on line 6 with your own condition.
Use WordPress native conditions that are available on WP Codex conditional tags.
https://codex.wordpress.org/Conditional_Tags
If you are using Oxygen and want de disable Oxygen CSS on those pages where Winden is enabled you can use another code snippet
In case if you are migrating completely from Oxygen and want to use Gutenberg of Bricks you can use plugin Freesoul Deactivate Plugins – Plugin manager and cleanup to disable oxygen per page