Closed MCatherine1994 closed 1 month ago
As discussed, we might like to do the SideNav change at this ticket or separate it into another ticket:
To accommodate the url requirement (/users/:userId/applications/:appId
), changes have to be made to the frontend router setup. There are two ways of doing this, using createWebHistory
or createWebHashHistory
.
The hash history is the easiest to convert to without doing any extra configuration to the front-end server. It is not SEO friendly, but for an app like FAM, it does not matter. Here is a detailed comparison between the two methods.
createWebHistory
(History API)Advantages:
#
symbol, making them cleaner and more readable (e.g., http://example.com/user-details/users/14/applications/11
).Disadvantages:
index.html
. If this isn’t configured, users may encounter 404 errors.Best For:
createWebHashHistory
(Hash Mode)Advantages:
#
is not sent to the server), no special server configuration is needed.Disadvantages:
#
symbol (e.g., http://example.com/#/user-details/users/14/applications/11
), which can look less professional or polished.#
symbol is generally associated with fragment identifiers (anchors) rather than navigation, which might feel less intuitive to some users.Best For:
If SEO and Clean URLs Are Important:
createWebHistory
is the better option. It provides a professional, SEO-friendly approach with clean URLs. However, it requires proper server configuration to handle deep links correctly.If You Want Simplicity and Compatibility:
createWebHashHistory
is simpler to implement, with no need for server configuration. It’s more foolproof in environments where server configuration might be complex or out of your control, but the URLs are less clean and not as SEO-friendly.For a public-facing site or where you control the server and need clean, SEO-friendly URLs, createWebHistory
is the way to go. For internal apps or simpler setups where you need to avoid server configuration hassles, createWebHashHistory
is a reliable, quick solution.
Describe the task Create a new user access history page
Acceptance Criteria
Additional context