1 + 2: After all, the maintenance of login status is nothing more than letting the client get a token that represents your login session after logging in. If you can get this, you will understand that it can actually be done by various means. It’s just one of the implementation options. So the key to this is that you handle the login well, and after logging in, the server registers a new token and issues the token to the client. As for the storage on the client side, it depends on your implementation, cookie / localStorage is fine, or you can simply use js variables to maintain it (if you don’t mind losing the state after refreshing)
3 - Yes, but if you use historyState, then configure try_files (or/and rewrite) so that the URLs are processed correctly
4 - This question is too general, search the documentation if needed
1 + 2: After all, the maintenance of login status is nothing more than letting the client get a token that represents your login session after logging in. If you can get this, you will understand that it can actually be done by various means. It’s just one of the implementation options. So the key to this is that you handle the login well, and after logging in, the server registers a new token and issues the token to the client. As for the storage on the client side, it depends on your implementation, cookie / localStorage is fine, or you can simply use js variables to maintain it (if you don’t mind losing the state after refreshing)
3 - Yes, but if you use historyState, then configure try_files (or/and rewrite) so that the URLs are processed correctly
4 - This question is too general, search the documentation if needed