-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintcache
1 lines (1 loc) · 6.68 KB
/
.eslintcache
1
[{"/home/shadab/Documents/shopping-cart/src/index.js":"1","/home/shadab/Documents/shopping-cart/src/App.js":"2","/home/shadab/Documents/shopping-cart/src/reportWebVitals.js":"3","/home/shadab/Documents/shopping-cart/src/components/Cart/Cart.js":"4","/home/shadab/Documents/shopping-cart/src/components/Home/Home.js":"5","/home/shadab/Documents/shopping-cart/src/components/Sidebar/Sidebar.js":"6","/home/shadab/Documents/shopping-cart/src/components/Topbar/Topbar.js":"7"},{"size":500,"mtime":1627883969451,"results":"8","hashOfConfig":"9"},{"size":122,"mtime":1627885343419,"results":"10","hashOfConfig":"9"},{"size":362,"mtime":1627883969451,"results":"11","hashOfConfig":"9"},{"size":3040,"mtime":1627888791043,"results":"12","hashOfConfig":"9"},{"size":4070,"mtime":1627890450060,"results":"13","hashOfConfig":"9"},{"size":673,"mtime":1627885595234,"results":"14","hashOfConfig":"9"},{"size":884,"mtime":1627884836899,"results":"15","hashOfConfig":"9"},{"filePath":"16","messages":"17","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"18"},"uznpmt",{"filePath":"19","messages":"20","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"18"},{"filePath":"21","messages":"22","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"18"},{"filePath":"23","messages":"24","errorCount":0,"fatalErrorCount":0,"warningCount":4,"fixableErrorCount":0,"fixableWarningCount":0,"source":"25","usedDeprecatedRules":"18"},{"filePath":"26","messages":"27","errorCount":0,"fatalErrorCount":0,"warningCount":1,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"28","messages":"29","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"18"},{"filePath":"30","messages":"31","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"18"},"/home/shadab/Documents/shopping-cart/src/index.js",[],["32","33"],"/home/shadab/Documents/shopping-cart/src/App.js",[],"/home/shadab/Documents/shopping-cart/src/reportWebVitals.js",[],"/home/shadab/Documents/shopping-cart/src/components/Cart/Cart.js",["34","35","36","37"],"import \"./Cart.css\";\n\nfunction totalPrice(products) {\n return products\n .reduce((acc, pro) => (acc += pro.price * pro.quantity), 0)\n .toFixed(2);\n}\nfunction Cart(props) {\n return (\n <div className=\"cart\">\n <div class=\"float-cart__header\">\n <h1 className=\"close\">Close</h1>\n <span class=\"bag\">\n <span class=\"bag__quantity\">\n {props.products.reduce((acc, pro) => (acc += pro.quantity), 0)}\n </span>\n </span>\n <span class=\"header-title\">Cart</span>\n </div>\n\n {props.product\n ? null\n : props.products.map((product) => {\n return (\n <div className=\"product-cart flex \" key={product}>\n <div className=\"product-img-cart\">\n <img\n src={\"/static/products/\" + product.sku + \"_2\" + \".jpg\"}\n alt={product.title}\n ></img>\n </div>\n <div className=\"product-text-cart\">\n <p className=\"product-title-cart\">{product.title}</p>\n <p className=\"style\">{product.style}</p>\n <p className=\"quantity\">Quantity: {product.quantity}</p>\n </div>\n\n <div className=\"product-price-cart\">\n <div className=\"remove-cart\">\n <img\n src=\"\\static\\sprite_delete-icon.png\"\n alt=\"delete-btn\"\n onClick={() => props.removeFromCart(product)}\n ></img>\n </div>\n <p className=\"product-price\">\n $ {(product.price * product.quantity).toFixed(1)}\n </p>\n <div className=\"controls\">\n <button\n disabled={product.quantity == 1}\n className=\"btn increase\"\n className={\n product.quantity == 1 ? \"disable btn\" : \"btn decrease\"\n }\n onClick={() => props.decreaseQuantity(product)}\n >\n -\n </button>\n <button\n className=\"btn increase\"\n onClick={() => {\n props.addToCart(product);\n }}\n >\n +\n </button>\n </div>\n </div>\n </div>\n );\n })}\n\n <div className=\"total flex justify-content flex-wrap\">\n <h5 className=\"total-text\">Total</h5>\n <h5 className=\"product-price\">$ {totalPrice(props.products)}</h5>\n <button\n className=\"checkout\"\n onClick={() =>\n alert(\n \" Order Of $ \" +\n totalPrice(props.products) +\n \"Successfully Placed\"\n )\n }\n >\n Checkout\n </button>\n </div>\n </div>\n );\n}\n\nexport default Cart;\n","/home/shadab/Documents/shopping-cart/src/components/Home/Home.js",["38"],"/home/shadab/Documents/shopping-cart/src/components/Sidebar/Sidebar.js",[],"/home/shadab/Documents/shopping-cart/src/components/Topbar/Topbar.js",[],{"ruleId":"39","replacedBy":"40"},{"ruleId":"41","replacedBy":"42"},{"ruleId":"43","severity":1,"message":"44","line":28,"column":67,"nodeType":"45","messageId":"46","endLine":28,"endColumn":68},{"ruleId":"47","severity":1,"message":"48","line":51,"column":50,"nodeType":"45","messageId":"49","endLine":51,"endColumn":52},{"ruleId":"50","severity":1,"message":"51","line":53,"column":23,"nodeType":"52","messageId":"53","endLine":55,"endColumn":24},{"ruleId":"47","severity":1,"message":"48","line":54,"column":42,"nodeType":"45","messageId":"49","endLine":54,"endColumn":44},{"ruleId":"47","severity":1,"message":"48","line":124,"column":42,"nodeType":"45","messageId":"49","endLine":124,"endColumn":44},"no-native-reassign",["54"],"no-negated-in-lhs",["55"],"no-useless-concat","Unexpected string concatenation of literals.","BinaryExpression","unexpectedConcat","eqeqeq","Expected '===' and instead saw '=='.","unexpected","react/jsx-no-duplicate-props","No duplicate props allowed","JSXAttribute","noDuplicateProps","no-global-assign","no-unsafe-negation"]