Question: I am using angular js [client side] and node js [for backend].
Which is more efficient and advisable when generating contents as csv,
a. writing the CSV generation, setting of fields [after fetching from backend node js] in client side [using angular or javascript] or
b. getting the CSV file as response from the backend?

Please let me know the pros and cons of both.

Answer: 
Assumed selected client-side CSV creation.

**Pros :**

* Choosing client-side csv creation; less tiring backend.
* If client has already data it will be useful, if back-end not need to response CSV file.

**Cons :** 

* If user has only ancient browser that time, he can't create CSV file.
* Your back-end will tire more.

So technically in all subjects(about performance etc.) developers can dive deeper. These are the basic pros and cons. Also pros and cons can be changed by other requirements or logics.
if the server just fetches data from db I guess it's better to put the `.csv` creation load to the client side; in this way server just sends the raw data to the client browser would do the processing and file creation.