Day 65: .env Files and the dotenv Package

Working on the final project in the web security section of the Node.js course from The Odin Project. I got caught in my own mistake of thinking that .env files would automatically load variables into my application. I spent some time trying to find a solution that did not involve using the dotenv package. Ultimately I read through the dotenv package’s code and decided to use it. That packages has tens of millions of downloads per week.

I am not a fan of just using any packages for all tasks because it leads to bloat in my projects. This package is fairly lightweight and is straightforward which I like. I started some notes on the package as well.

TLDR;

Okay, so here are the highlights of what I did:

  • Backend -> Continued working on the Members Only Project from the web security section. I did not have much time to work on the project. Moved my database connection string to my .env file.

Project Outline (Members Only Project)

Tasks

  • [x] Build out rough plan for project
  • [x] Build skeleton for project structure:
    • [x] routes
    • [x] models
    • [x] views
    • [x] controllers
  • [x] Build and test basic express app without authentication
  • [ ] Build out required Features as MVP
    • [ ] Build Authentication Feature
    • [ ] Build Login
    • [ ] Build Sign-up
    • [ ] Build Add New Message Form
    • [ ] Build Build Membership Sign-up
    • [ ] Build Build Admin sign-up
    • [ ] Build home page with Messages being displayed
    • [ ] Build user access limitations for messages and pages
  • [ ]
  • [ ]

Meta Data

Started On: 2022-08-27

References:

Reference Projects:


Goal For Round 8 of the #100DaysofCode Challenge

This is my eighth round of the “#100daysofcode” challenge. I will be continuing my work from round five, six, and seven into round eight. I was working through the book “Cracking the Coding Interview” by Gayle Laakmann McDowell. My goal was to become more familiar with algorithms and data structures. This goal was derived from my goal to better understand operating systems and key programs that I use in the terminal regularly e.g. Git. This goal was in turn derived from my desire to better understand the fundamental tools used for coding outside of popular GUIs. This in turn was derived from my desire to be a better back-end developer.

I am currently putting a pause on the algorithm work to build some backend/full stack projects. I primarily want to improve my skills with the back-end from an implementation perspective. I have improved tremendously in terminal and CLI skills but I lost focus due to how abstract the algorithm concepts got. I wanted to work on things that were more tangible until I can get to a position where I could directly benefit from improving my algorithm skills and theoretical knowledge. So that’s the focus right now. Build my backend skills and prove my full stack capabilities by building some dope projects.

Again, I still have no idea if my path is correct but I am walking down this road anyways. Worst case scenario I learn a whole bunch of stuff that will help me out on my own personal projects. Best case scenario I actually become one of those unicorn developers that go on to start a billion dollar company… You never know LOL.