I am developing a web application with angularjs as the front-end and a CRUD service at the backend. One of the requirements is to allow the user to upload a csv file containing a list of items to be created. This can be implemented on the front-end by parsing the file in javascript and making create API call to the server for each item. However, I am an not sure if this approach is better than passing the file to the server and doing all the processing there. What are advantages/disadvantages of both these approaches? What is the common practice in such a scenario?
Front end and back end development are two vital areas of coding. Front end development describes that programming that is done to a site to impact the client-side or the user side of a website or application. Back end development is the programming done to the server-side or the side that only a developer sees.
Front end development is programming which focuses on the visual elements of a website or app that a user will interact with (the client side). Meanwhile, back end development focuses on the side of a website users can't see (the server side).
Even if your ultimate goal is to become a back end or full stack developer, experienced developers might recommend that you master front-end development first. By understanding how the front end of websites are built, you can identify ways to make applications run more smoothly behind the scenes.
Front-end processing aims to collect information from the cardholder via the merchant and send it to the appropriate parties. This information is collected and routed through a payment gateway.
There are 4 things that I would use to make this decision:
Do you have very high load. If you parse it on the client you are using the clients CPU. Parsing it on the server could cost you by needing more CPU's.
Access to developer talent, is your team more productive programming it on the client or the server side.
If the answer to the above does not give a clear answer, then I would put it on the server side as it would be easier to test.
Will the "upload TSV" functionality be used by other parties/apps, who consume your API -- or is only the frontend using this functionality ?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With