expressCart/lib/modules/shipping-basic.js

14 lines
227 B
JavaScript
Raw Normal View History

2020-01-03 18:21:24 +10:00
const shippingAmount = 10;
const freeThreshold = 100;
const calculateShipping = (amount) => {
if(amount >= freeThreshold){
return 0;
}
return shippingAmount;
};
module.exports = {
calculateShipping
};