Exclude JS Script From Deferral
-
Hello,
I am having difficulty excluding a script from JS deferral (JS defer is stopping it from loading at checkout).
Script:
<script src="https://maps.googleapis.com/maps/api/js?key=AIzaSyAAQnz1kJ9fG-wqQ6IVDORsA9MPR5cYj9w&language=en&libraries=places&v=weekly&ver=1.0.9" id="aafw-googleapis-js"></script>
I have tried the following to no avail:
add_filter( 'sgo_js_async_exclude', 'js_async_exclude' ); function js_async_exclude( $exclude_list ) { $exclude_list[] = 'aafw-googleapis-js'; $exclude_list[] = 'maps.googleapis.com'; return $exclude_list; }
Probably making a very stupid mistake, if anyone can point out the obvious for me that would be very useful.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Exclude JS Script From Deferral’ is closed to new replies.