Heartbeat api not loading
-
I am creating a theme that will use the heartbeat api on a few pages. I a plugin I was developing recently, I loaded the heartbeat api simply with:
wp_enqueue_script(‘heartbeat’);
And that would load heartbeat.min.js into the page. It seems that it also created the javascript variable for the heartbeat settings.
However, in my new theme that uses the heartbeat api, enqueueing this script did nothing. I had to manually add the script into the page template, as well as have the template generate the heartbeat settings variable with a nonce. That is fine, and it works, but I wonder why the heartbeat api was not loading. Any answers?
The topic ‘Heartbeat api not loading’ is closed to new replies.