
This plugin adds SCSS functionality, compresses JS for you and creates an easy way to enqueue scripts and styles as well as localize them.
Let’s assume this structure:
your theme
├── assets
│ ├── js
│ │ └── script.js
│ └── scss
│ └── style.scss
├── functions.php
└── …
You can now do this in your functions.php with styles:
<?php add_action('wp_enqueue_scripts', static function(){ /* Full version */ \EasySCSSandJS\Styles::add('my_style_handle', __DIR__ .'/assets/scss/style.scss', [],[], true); /* Shortest version */ \EasySCSSandJS\Styles::add('my_style_handle', __DIR__ .'/assets/scss/style.scss'); /* Add dependencies (example: depends on handle 'bootstrap') */ \EasySCSSandJS\Styles::add('my_style_handle', __DIR__ .'/assets/scss/style.scss', ['bootstrap']); /* Add variables */ \EasySCSSandJS\Styles::add('my_style_handle', __DIR__ .'/assets/scss/style.scss', [], [ 'my_cool_color' => '#0000ff', ]); /* Enqueue it yourself */ \EasySCSSandJS\Styles::add('my_style_handle', __DIR__ .'/assets/scss/style.scss', [], [], false); wp_enqueue_style('my_style_handle'); }); And this with scripts:
<?php add_action('wp_enqueue_scripts', static function(){ /* Full version */ \EasySCSSandJS\Scripts::add('my_script_handle', __DIR__ .'/assets/js/script.js', ['jquery'], [], true, true); /* Shortest version (jquery is by default a dependency) */ \EasySCSSandJS\Scripts::add('my_script_handle', __DIR__ .'/assets/js/script.js'); /* No dependencies (also no jquery) */ \EasySCSSandJS\Scripts::add('my_script_handle', __DIR__ .'/assets/js/script.js', []); /* Add dependencies (besides jquery) */ \EasySCSSandJS\Scripts::add('my_script_handle', __DIR__ .'/assets/js/script.js', ['jquery', 'other_script']); /* Add variables */ \EasySCSSandJS\Scripts::add('my_script_handle', __DIR__ .'/assets/js/script.js', ['jquery'], [ 'my_variable' => 'testing this awesome plugin', ]); /* Enqueue it yourself */ \EasySCSSandJS\Scripts::add('my_script_handle', __DIR__ .'/assets/js/script.js', ['jquery'], [], false); wp_enqueue_script('my_script_handle'); /* Add the script to the header instead of the footer */ \EasySCSSandJS\Scripts::add('my_script_handle', __DIR__ .'/assets/js/script.js', ['jquery'], [], true, false); }); Use variables in SCSS:
// This is recommended. It will throw a fatal error if your PHP doesn't set the variable for some reason. // If PHP does set it, it will replace $my_cool_color with the defined color in PHP. $my_cool_color: #ffffff !default; body{ background-color: $my_cool_color; // This will be blue (#0000ff) } Use variables in JS:
alert(my_script_handle_vars.my_variable);
Compiled files will be saved in wp-content/uploads/compiled-scss-and-js. When that folder is cleared, everything will be regenerated.
There are filters for adding generic variables to all (or a selection) of scripts and styles or for adding extra content to files:
– easy_scss_extra_variables
– easy_scss_add_code_before_content
– easy_scss_add_code_after_content
– easy_scss_create_source_map
– easy_scss_storage_folder_name
– easy_scss_storage_folder
– easy_scss_storage_folder_url
– easy_scss_after_compilation
– easy_js_extra_variables
– easy_js_storage_folder_name
– easy_js_storage_folder
– easy_js_storage_folder_url
– easy_js_after_compilation
Starting from $0 per month.
Rating
Reviewers
1 reviews
Tags
Developed By
Lars Jansen
Quick & Easy
Common Ninja has a large selection of powerful Wordpress plugins that are easy to use, fully customizable, mobile-friendly and rich with features — so be sure to check them out!
Testimonial plugins for Wordpress
Contact Form plugins for Wordpress
Maps plugins for Wordpress
Translation plugins for Wordpress
Chat plugins for Wordpress
Slider plugins for Wordpress
Reviews plugins for Wordpress
Contact plugins for Wordpress
Galleries plugins for Wordpress
SEO plugins for Wordpress
Forms plugins for Wordpress
Comments plugins for Wordpress
Backup plugins for Wordpress
Privacy plugins for Wordpress
Optimize plugins for Wordpress
Tabs plugins for Wordpress
Social Sharing plugins for Wordpress
Events Calendar plugins for Wordpress
Comments plugins for Wordpress
Social Feeds plugins for Wordpress
Social Sharing plugins for Wordpress
Portfolio plugins for Wordpress
Video Player plugins for Wordpress
popup plugins for Wordpress
SiteMap plugins for Wordpress
Payment plugins for Wordpress
Coming Soon plugins for Wordpress
Inventory plugins for Wordpress
Testimonials plugins for Wordpress
Portfolio plugins for Wordpress
Membership plugins for Wordpress
Forms plugins for Wordpress
Analytics plugins for Wordpress
Events Calendar plugins for Wordpress
Sliders plugins for Wordpress
Analytics plugins for Wordpress
Reviews plugins for Wordpress
Security plugins for Wordpress
Ads plugins for Wordpress
Music Player plugins for Wordpress
Countdown plugins for Wordpress
Email Marketing plugins for Wordpress
Membership plugins for Wordpress
Ecommerce plugins for Wordpress
Customer Support plugins for Wordpress
Video Player plugins for Wordpress
Tabs plugins for Wordpress
Social Feeds plugins for Wordpress
Common Ninja Apps
Browse our extensive collection of compatible plugins, and easily embed them on any website, blog, online store, e-commerce platform, or site builder.
Create engaging stop motion displays with a stop motion player that turns image sequences into interactive animations to boost creativity and visitor engagement.

Show Blogger posts automatically with a Blogger feed that keeps your content fresh, improves navigation, and helps visitors discover more of your work.
Show TikTok videos with a TikTok slider that displays clips in an engaging, customizable slideshow to boost visibility and keep visitors watching.
Use tilted image effects to rotate visuals, add creative style, and keep visitors engaged with dynamic images on your site.
Use an event list to highlight upcoming activities, improve visibility, and help visitors discover events that increase attendance and engagement.
Use a reviews badge to highlight your ratings, build trust at a glance, improve credibility, and help increase conversions across your site.
Show a GDPR-ready cookie notice that clearly explains how cookies are used, helping you stay compliant while creating a more transparent experience for your visitors.
Show trust badges that highlight security and reliability, build customer confidence, and help visitors feel safe making purchases on your site.
Add a donation button that lets users contribute easily using PayPal or Stripe, supporting causes directly from your site.
Show Bluesky posts with a Bluesky feed slider that scrolls updates and keeps content visible while keeping visitors engaged.
Display social proof avatars that show user activity and ratings, build trust instantly, and help visitors feel confident about your credibility.
Show products, apps, or designs inside a clean device mockup that improves visualization, builds credibility, and helps visitors make confident decisions.
More plugins
The Common Ninja Search Engine platform helps website builders find the best site widgets, apps, plugins, tools, add-ons, and extensions! Compatible with all major website building platforms - big or small - and updated regularly, our Search Engine tool provides you with the business tools your site needs!
