Questions tagged [single-page-apps]
27 questions
5
votes
1 answer
Implementing clean architecture
I just read the book 'clean architecture' by Uncle Bob and really like the approach.
But the big disappointment came when I tried to implement it in C#.
I really hope you can help me with some questions.
What I tried was to implement the following…

David Mason
- 321
- 3
- 7
5
votes
3 answers
Using SPA ( Single-page-application) in production with separate configuration file/module
Problem statement
dev team
Dev team wants to pre-build the SPA's (Angular App & React App) and provide single package containing JS, CSS, & HTML file. There's no server-side rendering / lazy loading also. Hence, configurations like service URL, app…

Prajwal
- 161
- 1
- 5
4
votes
2 answers
Is there a canonical definition of SPA or is SPA a broadly agreed-on architecture with fuzzy edges?
Is there a canonical definition of SPA which would exclude the software architecture model described below?
I'm working on an app with a new web-architecture model (new to me, at any rate) which has features that differentiate it from a Single Page…

Rounin
- 275
- 1
- 10
4
votes
0 answers
How to implement SAML Authentication SPA and REST Backend
Developing a SPA (with VueJS) that is talking to our own REST API Backend(Separate server). Normal authentication flow in the SPA:
User credentials after submission are sent to the backend and if authentication is successful a token is returned…

Matt
- 141
- 3
4
votes
1 answer
Split large Angular codebase to libraries
I am writing a potentially large web application using Angular 7, where I came across a design problem. My angular applications until now have been relatively small, so there was no problem keeping whole code in one project (divided in modules with…

Miha Jamsek
- 249
- 2
- 7
3
votes
3 answers
Solution to notify users Single Page Application (SPA) static resources have updated if users don't refresh their browsers
I need to design a way to notify my user the SPA has updated if they don't refresh their browsers, i.e. if no requests to get index.html is made after the initial load, how do I notify users the javascript or css files have updated on the server?…

Qiulang 邱朗
- 3,095
- 3
- 13
- 22
2
votes
1 answer
Many small files vs fewer larger files: impact on bundle size and build time
I've been a relentless proponent of small files. I prefer one function export per file, functions with everything-in-one-view, and breaking up UI components as much as sensible (which is why I love React).
There are many benefits to this from a…

Faust
- 139
- 7
2
votes
1 answer
How to avoid duplicated logic on frontend SPA and backend API
Every time I'm working on an SPA with an API backend I always find myself wondering the best way to do this. The current example I'm running into is as follows:
When a User has their account created for them (by an admin user), they are sent a…

Matthew Weeks
- 141
- 6
2
votes
0 answers
Architecting OAuth2 Flow With an API and Static JS Client
I'm building a very security conscious application. (All applications should be security conscious, but this one may contain a lot of red data).
Assuming that I will use a Vue/React JavaScript Single Page App that will authenticate with Google for…

user974407
- 211
- 2
- 6
2
votes
0 answers
How to define REST endpoint for subresource of not saved resource
I have REST API for my SPA application.
My domain model has Order entity, it has Commission property which calculated on backend, it is number value
For get Order entity SPA calls this endpoint, this endpoint returns saved order
GET…

Andrey G.
- 29
- 1
2
votes
1 answer
Does Flux/Redux concept about application state put bounds on the size of application?
In Redux (React Flux implementation) guide https://redux.js.org/basics/reducers it is said, that
In Redux, all the application state is stored as a single object
My questions are:
How seriously we should take this principle? E.g. my application…

TomR
- 1,003
- 1
- 9
- 17
1
vote
1 answer
Is storing access token in private data, refresh token in http-only cookie safe?
Backend: Django / Django Rest Framework, would be hosted at GCP k8s
Frontend: Angular, would be hosted at some CDN e.g Vercel
Authentication: JWT (https://github.com/jazzband/djangorestframework-simplejwt)
The frontend and backend would have…

AhmedBilal
- 65
- 7
1
vote
2 answers
Semantic versioning for SPA applications with a RESTful backend
I am building an Angular web application with a RESTful backend. I plan on using semantic versioning to differentiate between different releases. I've already read a bit about how to implement semantic versioning for web applications but I'm still…

Maurice
- 133
- 7
1
vote
1 answer
SPA Routing with a RESTful API using HATEOAS
When using routing in a SPA web app (angular, react, etc), the user doesn't have to start at the entry point of the application. They can use a URL in the browser to drill down into any part of the application.
When implementing HATEOAS in a RESTful…

wired_in
- 322
- 1
- 2
- 8
1
vote
1 answer
How to implement authorization restrictions with SPA pages?
I have read this below answer for SPA cons. In fact, I have faced some problems outlined.
https://stackoverflow.com/questions/21862054/single-page-application-advantages-and-disadvantages#answer-37443637
That is why I want to check i still taking…

Durai
- 119
- 1