Replies: 9 comments 15 replies
|
I now solved this by overwriting The middleware is using supabase Additionally overwriting the navigation of Docus in |
|
I just realized that this still leaves |
|
Hi @oripka, |
|
Additionally to what I mentioned above. I found out that one can protect But I also noted that it doesn't fully protect the content e.g. somebody can still just download I read through some of the Content and Docus code but my I still feel that I don't understand exactly how to do this with the least amount of friction.
Here the server middleware (code is bit rough right now, but you should get the idea.) With the server middleware I ran into performance problems and also the issue that |
|
Hi! Thanks for your contribution! Have you solved this problem now? I'm also working on this problem, but I still have no solutions... I'm wondering, does your solution (superbase + nuxt content) works well now? |
|
I just thought about this conversation again and wrote the following simple middleware. Now when I make a request to |
|
I had a lot of performance issues with my solution above. It turned out that this part of the solution was the issue:
Not sure how to protect the document driven pages without using an auth middleware and running into these performance issues |
|
A completely different solution could be to relocate your content to supabase storage and use their authentication. |
|
Has anyone ever come up with a proper solution to this? Considering Nuxt and Nuxt Content have quite evolved in the past two years... |
Uh oh!
There was an error while loading. Please reload this page.
I'm using Nuxt Content as a tutorial / lab guide system for some courses. It's really nice to be able to do little quizes by implementing them as MDC.
I also implemented a way to convert the the markdown content to PDF, as students of courses often want to have a definitive PDF to take home with them (in the fear that the website will not be around forever). This is based upon pandoc, eisvogel.tex, some python scripting and Docker, CI/CD.
Back to my original question. I found this issue #520 for v1. There is some talk about implementing authenticated access to
contentin v2. Is that actually possible now? It would be really nice to not have to put the markdown into a database in order to protect it.Until now I figured that I can just use the authentication in the Vue Components but I am not sure how to properly prevent access to the markdown content.
All the best
All reactions