API layered architecture
Hi, I'm trying to apply the concepts of a layered architecture on a file upload API. Currently I have a folder structure that resembles this:
Inside
Cheers!
Inside
file.repository.ts will be all functionality related to talking to the database. However, I intend to save the uploaded files on the server instead of using a 3rd party service for this, mainly for practice purposes. The question then is, where would this functionality (reading from and writing to disk) live? Inside services? Repository? Or should I create a whole new domain (maybe called io or something) just for this?Cheers!
