You appear to be a bot. Output may be restricted
Description
Overrides parent method.
Usage
BackCompatAssetDataRegistry::enqueue_asset_data();
Parameters
Returns
void
Source
File name: woocommerce/packages/woocommerce-blocks/src/Assets/BackCompatAssetDataRegistry.php
Lines:
1 to 24 of 24
public function enqueue_asset_data() { $this->initialize_core_data(); $this->execute_lazy_data(); /** * Back-compat filter, developers, use 'woocommerce_shared_settings' * filter, not this one. * * @deprecated 2.5.0 */ $data = apply_filters( 'woocommerce_components_settings', $this->get() ); $data = rawurlencode( wp_json_encode( $data ) ); // for back compat with wc-admin (or other plugins) that expects // wcSettings to be always available. // @see https://github.com/woocommerce/woocommerce-gutenberg-products-block/issues/932. echo '<script>'; echo "var wcSettings = wcSettings || JSON.parse( decodeURIComponent( '" . esc_js( $data ) . "' ) );"; echo '</script>'; }