Created
January 5, 2023 11:17
-
-
Save uptheirons78/b21c8006f83c3dc0775012f21fd03fdf to your computer and use it in GitHub Desktop.
All In One WP Migration: exclude node_modules from export files
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* All In One WP Migration: exclude node_modules folder from export files | |
* | |
* Change 'your-theme-name' with the real name of your theme folder | |
* save this file inside your 'inc' folder and require it inside 'functions.php' | |
* | |
* @package Your_Theme_Name | |
*/ | |
function mb_ai1wm_exclude_node_modules($exclude_filters) { | |
$exclude_filters[] = 'your-theme-name/node_modules'; | |
return $exclude_filters; | |
} | |
add_filter('ai1wm_exclude_themes_from_export', 'mb_ai1wm_exclude_node_modules'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment