Asset Loading

etchKit only loads its CSS and JavaScript on the Etch builder page. Nothing is enqueued on the public-facing site, in the WordPress admin dashboard, or on any other backend page.

When assets load #

The plugin checks for two conditions before enqueuing anything:

  1. The current page is the Etch builder (identified by the ?etch=magic query parameter)
  2. The current user is logged in and has the edit_posts capability

Both conditions must be true. If either fails, no etchKit assets are added to the page.

What gets loaded #

Two files are enqueued:

  • assets/css/panel.css for all panel styles
  • assets/js/panel.js for all panel logic

The JavaScript file is loaded with the defer attribute so it never blocks page rendering. The Etch builder and all its own assets load first, and the etchKit panel initializes after the page is ready.

Performance impact #

Because assets only load on the builder page for logged-in editors, etchKit adds zero weight to your front-end. Visitors to your site never download the panel CSS or JavaScript. There is no database query involved in loading the panel either. The only server-side work is the REST API call to fetch the library JSON, which is cached via both a WordPress transient and browser-side ETag headers (see REST API for details).

What are your feelings

Updated on 31/03/2026