Javascript practice ecommerce