WP Manifestindependent plugin directory
manifest / content / acf-flexible-auto-assets

Auto Assets for ACF Flexible Content

Automatically enqueue CSS and JavaScript files for ACF Flexible Content blocks

★ 5stars
v1.0.0latest · 1 year ago

Install

Download source zip No release zip yet

This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.

Install straight from GitHub with WP-CLI:

wp plugin install https://github.com/szepeviktor/acf-flexible-auto-assets/archive/refs/heads/master.zip

On Packagist as szepeviktor/acf-flexible-auto-assets:

composer require szepeviktor/acf-flexible-auto-assets
No built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.

Automatically enqueue CSS and JavaScript files for ACF Flexible Content blocks.

Installation

Here is the plugin ZIP https://github.com/szepeviktor/acf-flexible-auto-assets/archive/refs/heads/master.zip

Usage

Name your asset handle like this.

add_action('wp', function () {
    $handle = 'acf_flex_' . $field_name . '_' . $block_name;
    wp_register_style($handle, plugins_url('my-plugin/flex/the-block.css'), [], MY_PLUGIN_VERSION);
});

Assets for template files

<?php

/*
 * Template Name: My template
 */

wp_enqueue_style('my_css');
wp_enqueue_script('my_javascript');
get_header();

?>

Releases

1 release.

Tag
Published
v1.0.0 latest
May 21, 2025 1 year ago

These releases are tags only. The author does not attach a packaged zip, so there are no download counts to report.