How to properly separate the client and server side?

  • 0
    Good evening, there was a question about choosing a structure for a web application.
    The application will represent a client in React and a server in Laravel, using the REST API, and also make a mobile application in the project.
    What is the best way to organize the structure?
    Now 2 options come to mind.
    1. Make 2 folders client and server and store everything in one repository.
    2. Split client and server into different repositories, and deploy them separately.

    For now, I'm leaning more towards the second option, since in the future it is possible to deploy multiple servers with load balancing between them.

    I would be glad to hear comments or suggestions on the issue. Thanks in advance
    JavaScript Anonymous, May 19, 2019

  • 2 Answers
  • 0
    2 repositories. There is no need for each side to carry an extra load.

    When rolled out to a server, it can be stored in just 2 folders, client and server.

  • 0
    You can make a monolith, since logically you will still have one application

Your Answer
To place the code, please use CodePen or similar tool. Thanks you!