Closed jerriclynsjohn closed 3 years ago
@jerriclynsjohn I see 0 reason why this wouldn't be possible in both SSG and SSR mode if all of the data fetching is done with a JWT on the client for the logged in components.
If you want to make the experience dynamic in a SSR context, you could also achieve what you are looking for but with a different flow.
Have anyone tried authenticated pages in ElderJS, I'm thinking out loud here:
My requirement is to show a certain part of the page to only authenticated users and give them the ability to comment, like, and even take courses.
Example - Comment Component A blog page where a comment component is read-only and shows a CTA for login for non-authenticated users and for authenticated users it gives the user ability to comment and like/dislike other comments.
What I'm thinking could be a solution
I'm hoping that we can make use of the "hydration" feature of Elder to build SEO-friendly & static websites that can highly be interactive. I wanted to know what the community has learned about any such implementations in the past, learn from them, and then implement them for my project.