title: Architecture for an integrated offline windows + Web + android application with minimal duplicate effort
body: <p>We are looking to develop an application wherein the requirement is such that we need some help on designing the architecture. I am putting down below the requirements of the application.</p>
  
  <p><strong>Brief Description</strong></p>
  
  <p>1) The application <strong>shall work on web + Android + Offline desktop version</strong> (Offline version meaning entirely offline environment wherein full functionality shall work without internet) </p>
  
  <ul>
  <li>if possible offline android as well (which as per my research is difficult to do in same backend so caching can be used for temporary offline usage)</li>
  </ul>
  
  <p>2) While designing the architecture we want to <strong>minimise the rework</strong> such that we shall be able to <strong>use the same Database, Logic code and Frontend as much as possible</strong></p>
  
  <p>3) Everytime <strong>application is updated</strong> then web and android will reflect it immediately due to API integration. And for offline application, we want to update the logic and database everytime it connects to internet.</p>
  
  <p><strong>Challenges I am facing</strong></p>
  
  <p>1) <strong>Database choice</strong> : Since it has to be an offline solution as well, I understand that we will have to use either SQLite or SQL compact edition so that we can use the free version and installation file is also not very big</p>
  
  <p>2) <strong>Logic</strong> : Due to offline requirement, we may have to put entire logic in Asp.net / (any other suggestions) since stored procedures are not supported in above mentioned databases
  Some links I found regarding this :</p>
  
  <p><a href="https://www.codeproject.com/Questions/346702/How-to-make-work-an-Online-Web-application-Offline" rel="nofollow noreferrer">https://www.codeproject.com/Questions/346702/How-to-make-work-an-Online-Web-application-Offline</a></p>
  
  <p>3) <strong>Application framework</strong> : Which framework MVC / MVVM etc would be suitable to minimise the work for web based and offline app. </p>
  
  <p>4) <strong>Frontend</strong> : I understand that we will have to make different screens for web and android. However want to know whether we can use HTML 5 (cache feature) or Angular JS which can be used in offline environment as well or do we have to make offline screens seperately?</p>
  
  <p><a href="https://stackoverflow.com/questions/18102002/build-an-asp-net-web-app-with-offline-functionality">Build an ASP.Net web app with offline functionality</a>
  <a href="https://www.html5rocks.com/en/tutorials/appcache/beginner/" rel="nofollow noreferrer">https://www.html5rocks.com/en/tutorials/appcache/beginner/</a></p>
  
  <p>5) Can <strong>apache cordova</strong> be used in someway for better architecture (I dont know much about it hence)</p>
  
  <p>6) I am sure I might be missing something. If you can offer some suggestion on best way to go about developing this application then will really appreciate your help</p>