get the cart items data in Shopify

Add the following code to your liquid file: get the cart items data in Shopifyexpoundsofttechsolution get the cart items data in Shopify
jQuery.ajax({
        type: 'GET',
        url: '/cart.js',
        dataType: 'json',
        success: function(cart) {
          console.log(cart);
        }
    });