DEV Community

Cover image for A new project. Back to basics
Rhymes Toasterface
Rhymes Toasterface

Posted on • Edited on • Originally published at triplejdeveloping.com

1

A new project. Back to basics

Episode one - a new thing

3/5/20 Background and Plan

So, I wanted to make me a React. Because I don't really know how to. So I dived straight in.

I wanted to make a website to keep all of our favourite recipes in one place. Toasterfaves. Save using that minging old recipe book we have.

Then I thought about it...

What I actually wanted to make was an end to end app. FULL STACK BRO BRO. YEAH. BRO. Or something.

So I started back right from the very beginning.

Maybe it will help someone. Maybe not. But it might help me...

First step - start React Udemy course.

Second step - ignore that and start again.

Third step - start writing the api for the app.

Fourth step - ignore that and start at the VERY BEGINNING.

REAL first step - hosting.

I already have a website. I've had it for a very long time. As you can probably see from that website, I changed careers a few years back. I quit my office job and went to a coding bootcamp. The course was based around PHP/LAMP stack, but covered a bit of node towards the end. When I finished the course, I started writing a cms for a website for a private client. I used php - it was the most knowledge I had. I got some cheap Linux cpanel hosting and away I went. Everything on there is PHP. I've wanted to change over to node (I have been a sefver side dev for a few years now, and that is all written in node), but didn't get round to it - I didn't have ssh permissions for the server blah blah blah so made excuses to put it to the back of the pile. I thought now was maybe the time to get it to the top of the pile!

This will be a series.

I don't promise to release a new one on a schedule - I have too many kids to make promises like that. When I get round to doing a new bit of the project, I will write some more up.

These are the things I plan to cover in this series:

Get the server set up:

  • Install node using nvm, to be able to manage the version easily
  • Use a database - I plan to use mongo, just because it is what I know and super easy to use
    • I haven't decided whether to install it on the server and hold the dbs there - I could run a cron job on the cpanel to back up the data/dbs directory that mongo uses, but at the same time, I could just use atlas - mongo has a free tier and I don't plan to go over that - I was going to make a simple site to hold cooking recipes.
    • Atlas is probably a nicer idea - just in case 1 BILLION people want to copy my banging thai sweet potato and chicken soup
    • Connecting to atlas might be more interesting and a more useful use case for others
    • I might struggle to get set up on the server as I have no access to sudo or even su. There is no apk or yum. It's going to be a fun ride...
  • Figure out how to expose the backend api through this server
    • Create an api for the app
    • As I said, I plan to use the app for recipes, but it could go on to be used for a blog, for example, or other things
    • Basic crud routes, with authentication
    • Storing images - who wants to read about food without seeing a picture of some???
      • I have toyed with the idea of storing images in a db as base64 for a while. At work, we store in an s3 bucket - this is another option - AWS has free tiers and access or size shouldn't be a problem.
  • Create a front end for the app
    • Initially, I want to create a front end to display the stuff - I plan to use react, because I am interested, but may try Vue or A.N.Other by the time I get to this stage...
    • I haven't planned to set up a front end for the creation of items/recipes/whatevers.
    • This will probably come later on
    • Can use postman in the interim once the api is up and running
    • There is an admin section of my website, so I can put it behind there, but it isn't a big deal for me right now

Originially published at triplejdeveloping

Top comments (0)

Sentry image

See why 4M developers consider Sentry, “not bad.”

Fixing code doesn’t have to be the worst part of your day. Learn how Sentry can help.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay