export default {

    toFixed(price,size=2){
        return parseFloat(price).toFixed(2);
    },

    toIntOrFloat(price){

        if (price) {
            price = parseFloat(price);

            let intPrice = Math.floor(price);

            if (price === intPrice) {
                return  intPrice;
            } else {
                return  price;
            }
        } else {
            return  0;
        }


    }

}