Yesterday night I thought to myself, wouldn’t it be great if a guest user could view a user profile? I argued against this a few months ago since it literally ruins the essence of regular users having to follow each other to view each others posts
Don’t get me wrong, I’d love users to follow, know each other and have meaningful conncections. However, it doesn’t work really well for non users who just want to view a profile.
So I decided to remove the ‘login_required’ requirements from the profile page and restructured most of the logic in the profile template to accomodate this drastic and rather experminental decision. The app crashed almost instantly with a dozen bugs regarding user permissions to view profiles.
I had to even deviate from my regular coding style to write coupled conditionals to offer different access points to unathenticated users, authenticated users, current_user following the user profile in view and if the user in view’s profile is private or has no posts to display. I wish to address this further.
This is how my Bambi profile looks like to a user who is not signed in
Notice how the follow drop down next to the verification mark is now missing. This will occur to all profiles viewed in guest mode. Moreover, you won’t be able to see when the user was last online on the left and also who the user follows or who follows the user.
On the profile page too, the posts have been shortened and you will have to log in to read the full posts on the profile.
For private profiles, you won’t be able to see their posts unless you log in.
Thats all for now. More changes will be on the backend. The following features are in the pipeline
- Ability to create communities to post and share stuff. You’ll have to join the community to post stuff eg school material & announcements, organize events or even share memes.
- Improved private messaging using Socket-IO
- An improved Marketplace feature that could also include apartment listings and a catalogue of restaurants to order take out.
- An improved algorithmic way of suggesting friends.
- A separate school feature which I have no idea how to implement yet but will spend a significant chunk of brainpower coming up with.
- A WYSIWYG editor to add posts with multimedia and link previews to bring posts to life
I am excited to see all this work coming to life harmoniously. I am now learning Django and building an e-commerce platform for rental listings and could incrorporate the feature into Bambi or host it seperately. All this will fall in place sooner than my modest anticipation
Would you please leave the lights on for me when you go to sleep tonight?