Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ability to set assets enqueue priority via configuration file #24

Closed
amostajo opened this issue Aug 16, 2020 · 1 comment
Closed

Ability to set assets enqueue priority via configuration file #24

amostajo opened this issue Aug 16, 2020 · 1 comment
Assignees
Milestone

Comments

@amostajo
Copy link

Currently, this is set to load at priority 10 (default on every WordPress hook).

Add the ability to set the hook priority via app/Config/app.php file, like:

return [
    'assets' => [
        'enqueue_priority' => 15,
    ],
];
@amostajo amostajo added this to the v3.1.14 milestone Sep 10, 2020
@amostajo amostajo self-assigned this Sep 10, 2020
amostajo added a commit that referenced this issue Sep 10, 2020
@amostajo
Copy link
Author

Added priority, configurable as:

return [
    'autoenqueue' => [
        // Enables or disables auto-enqueue of assets
        'enabled'       => true,
        // Enqueue priority
        'priority'      => 15,
        // Assets to auto-enqueue
        'assets'        => [],
    ],
];

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant