Lifelog

Write 100 words a day, every day, towards your goals.

πŸŽ‰πŸŽ‰πŸŽ‰ YAAASSSS ITS FIXED!!!! After 3 days of debugging trial by fire, I fixed the post page loading issue. Woohoooo I wanna dance hahahahah! πŸ•Ί

Turned out, the culprit was a sort function for the comments v-for loop.

v-for="comment in sortedComments"
:key="comment"
>
...
computed: {
sortedComments() {
const x = this.post.comments
return x.sort(function (a, b) {
return a.id - b.id
})
},
}

Changed that function to using lodash's sortBy function and it works now!

import _ from 'lodash'
computed: {
sortedComments() {
return _.orderBy(this.post.comments, ['created_at'], ['desc'])
},
},

All thanks to @yuyu 's suggestion to comment out everything in _slug! That got me down the right path to debug this eventually! Note to self: always fall back to fundamentals when debugging - just comment out code first to isolate the bug. But the deeper mystery remains:

* why this worked before but not now
* the behaviour should be consistent on local and production, but it worked on local
* the function didn't crash the page if I entered the site via a different child page by directly typing in the url
* why lodash worked but a vanilla JS script didn't

Day 7 - Chronotype metamorphosis complete https://golifelog.com/posts/chronotype-metamorphosis-complete-1609987348325

Day 6 - $5k MRR-Breaking it down https://golifelog.com/posts/dollar5k-mrr-breaking-it-down-1609908146149

To earn $5,000 monthly, I need:

50 people to pay $100/month
100 people to pay $50/month
200 people to pay $25/month
500 people to pay $10/month πŸ‘ˆ
1000 people to pay $5/month
5000 people to pay $1/month

Breaking it down in terms of actions:

$60k/year
… $5k/month
… $1250/week
… $166.66/day
… 10 people buy the $120 lifetime plan per week
… or 17 people sign up on the $10/m plan per day
… 1000-1700 views per day @ 1% conversion rate (assumed)

So my job now is to generate 1700 daily views ... πŸ€”

Researched about timezone management for apps

OK so this seems to be how the various packages should work on a high level:

* timezone detection - packages like jstz, moment.timezone.guess() to detect the tz of the user. These packages usually tap on the javascript Intl API
- Intl.DateTimeFormat.prototype.resolvedOptions()
* timezone library - a library of timezone offsets based on real world data (timezones are a mess, with daylight savings and all). This library would take the tz from the tx detection package, and pass on the offset needed calculate streaks
* streaks - calculate streaks data based on array of tz dates (I use date-streaks npm package)

Added feature/bug tags to roadmap

Learned something new today! I can actually v-bind a class attribute using the template literals `${ }`

:class="`is-${consideredFeature.typeColor}`"
Jason Leow Author

Thanks @yuyu! Great learning point, didn't know that! I just did what worked but this really helps. Must add this to future optim efforts

0 Likes
Yuyu

Probably not the best way if you intend to optimize it in the future: https://tailwindcss.com/docs/optimizing-for-production#removing-unused-css

0 Likes

Fixed Abe's streak manually

After some research and discussion with Abe, I think I know what went wrong with the streak mechanism. The npm `date streaks` package never calculated streaks based on timezones! Everything is in UTC +00 (as per recommended best practice of saving timestamps in databases). If users had very predictable routines of writing, it was still fine, but if someone wrote close to the end of their timezone windows, that might already be the next day in UTC time (thus broken streak). Need to look for a package that has a library of timezone offset rules to twin with my date streaks package, and perhaps another one too to detect user's timezone without user having to explicitly set it.

Day 5 - Biohacking sleep https://golifelog.com/posts/biohacking-sleep-1609833246396

Deployed roadmap page to

Felt like I made a mini-app within an app! Made this in 2 days - tabs for different upcoming features categories, with feature lists under each tab. Also added a few placeholders for upcoming features: upvote button, individual feature pages with comments threads for only logged in users.

Created component for roadmap page - tabs with a card/box-based list of features

Researched other feedback/roadmap tools, was either pricey (Canny.io) or didn't fit what I needed (Trello). So decided to make my own!

Created the roadmap page, since everyone is asking about it while giving feedback. 4 tabs - considering, planned, developing, launched. Each tab will have a list of features in card/box format, with future features like upvoting button, and comments thread upon click through to read/comment/discuss.
Jakub Dubec

@jasonleow Anyway its cool to have a writing streak, actually I am now on challenge to use paper diary for one month :D Thanks for inspirative update ;)

0 Likes
Jakub Dubec

Great! :-) Im curious what you will come up with soon. Leave me a note if you would like to localize it easily into more languages. We also have own tool for that :)

0 Likes

Day 4 - Why $5k MRR, not $1mil ARR? https://golifelog.com/posts/why-dollar5k-mrr-not-dollar1mil-arr-1609768815529

Fixed Keni's streak again. There's an issue alright, just that it's only affecting her, not the rest.How very odd.

Day 3 - 2021 in 8 forms of capital https://golifelog.com/posts/2021-in-8-forms-of-capital-1609644092355

In 2021, I want to see if I can…

πŸ’΅ Financial: Hit $5k MRR from all my products by 31 Dec 2021, through consistency rather than intensity.

βš’ Material: Give more, give away more.

🌲 Living: Sleep better, move more (& in nature).

πŸ’‘ Intellectual: Follow my dev nose.

πŸ’ͺ Experiential: Look for 1% improvement every week. Just 1%, 1 thing, 1 task, 1 idea.

πŸ‘₯ Social: Quality conversations and relationships, local and global.

🎨 Cultural: Changing lanes (and identity) to geek/dev subculture.

β›© Spiritual: Fatherhood that’s mindful and present.

πŸ€‘πŸ€‘Yaayy...2nd lifetime deal ($120) customer!! Thanks Eddie Choo!

Day 2 - 2020 review in 8 forms of capital https://golifelog.com/posts/2020-review-in-8-forms-of-capital-1609570126205

πŸ•ΊπŸ•Ί YAASS!! 2nd MRR ($10/m) customer just landed in. Thank you @haideralmosawi !!

Jason Leow Author

Cheers! I hope so too!

0 Likes
haideralmosawi

You deserve it for the great work. I look forward to seeing lifelog grow! 🀩

0 Likes

πŸ€‘ WOOHOO!!! Just got my first lifetime deal ($120) customer on Lifelog! Thank you @santhoshguru!

Fixed Keni's broken streak in database

Fixed it by manually changing the date of her last post in the database itself. Looks like there might be timezone issues...? Unsure at this point. Could be due to the switch over to using just dates instead of timestamptz via the SQL Date() function. Will have to continue monitoring...

✍️ My very FIRST post on this new year, on my new SaaS! Day 1 - Jumpstart January https://golifelog.com/posts/jumpstart-january-1609487053467

Bumped up Brandon's user id from 9 to 3, because sometimes it matters!

πŸ€©πŸ€‘πŸ˜First MRR dollar just landed!!! Now at $10 MRR

I know this means nothing and users will churn, but HELL YEAAAHHHHHH my first MRR dollar! 🍻

πŸš€ Just pressed the button on a soft launch for Lifelog! Wooohooo here goes nothing!

Ending this crummy year with a highlight from my #decodingcoding journey - my very first SaaS!

Lifelog is a platform to write everyday towards your goals. Having wrote daily for 2 years straight, I’m a big believer in the power of writing to think, plan, imagine and realising your goals. Those who are revving up for a change in 2021 with ambitious goals, start here:

https://golifelog.com

I spent 3 months on this... coding the functionality bit by bit, realising it can actually work, and then design-developing the writing UI from zero. I’d not worked this hard on a software product before, but pleased with how much fun I had learning new programming languages/frameworks as I go, and how it turned out in the end.

The best part, I’m making a tool for myself as I continue my daily words after this break. It’s kinda freeing to know that, even if no one else uses this tool, it’ll still be useful to one user (ie me!). But of course, I’m banking on the fact that there’s more folks like me out there who enjoying writing, thinking and achieving. 😎

For the tech-savvy, my tech stack is Nuxt.js/Vue.js + Bulma on frontend, and a headless CMS/API builder called Strapi (based on Node.js) on backend, all hosted on Heroku.
Jason Leow Author

Thank you Nick! 🍻

0 Likes
Nic Coates

Congrats on the soft launch Jason πŸŽ‰

0 Likes

πŸš€ Set up custom domain on Heroku via Cloudflare...for FREE! Annnd it's now live https://golifelog.com

Cloudflare is awesoommmmme! Heroku allows for free custom domain but not SSL, so Cloudflare to the rescue. Cloudflare even has apps like welcome bar, secuity, chat, that you can 1-click install. Fascinating how they can do that without the user having to embed any script or install packages.

Added favicon, og:image, and all meta tags to

Tried Netlify prerendering but didn't seem to help much with Lighthouse scores...anyone had a similar/different experience?
Jason Leow Author

@knight can't wait! πŸ’ͺ

0 Likes
Knight Tan

joined and going to start in 1st Jan :P

0 Likes

Updated DNS from Namecheap to Netlify, now just have to sit on my hands for 24-48h πŸ˜‘

Records updated and propagated in record time, in 1-2h!!! Netlify is niiiice