Rainbow treasures
Home » Rainbow treasures
1373 GIRL’S MEGI T-SHIRT WITH PANT
482.50৳
1381 GIRL’S T-SHIRT WITH LEGGINGS
664.00৳
1602 GIRL’S T-SHIRT
224.50৳
1601 GIRL’S T-SHIRT
224.50৳
1439 GIRL’S T-SHIRT
324.50৳
// Function to calculate discounted percentage
// Sample array of products
// Loop over each product
// Retrieve original price
let originalPrice = parseFloat(originalPriceElement.textContent.replace('$', '')); // Assuming prices are in USD
// Retrieve discounted price
// Check if discounted price element exists
let discountedPrice = parseFloat(discountedPriceElement.textContent.replace('$', '')); // Assuming prices are in USD
// Calculate discounted percentage
// Create a element to display discounted percentage
// Insert the element into the product
// Handle case where discounted price is not available
// Call calculateDiscountedPercentage function initially
// Attach event listener to tab buttons
// Wait for a short delay to ensure the new content is loaded
// Call calculateDiscountedPercentage function after a short delay