Hello great people! 👋
I'm back with some interesting info for you. As software people, we do some planning in our day to day life. One of the most important plans is the planning for our project before we start coding.
A common mistake we (software people) do is that, we think it's very obvious and we don't need to WASTE(!!) time to write them down. Then at some point, we find ourselves overwhelmed with the project!
Generally, I like to write everything down. This way I keep my mind free. Here is my philosophy behind this.
Don't store data in RAM (your mind), when you can store it in a hard disk (paper/ online platform).
Take this example, if I tell you that there will be a software that uses facebook API to send messages to users. To many, it is very INTUITIVE. But the reality is that, it will have a lot of moving parts and if you don't take care of them, you will have a lot of headache soon.
Recently I made a boilerplate to kickoff a project and I thought it may help some of my fellow software people. So, here is the boilerplate that may work fine for small and medium size software.
Consider the stacks as placeholders. Replace with the one that works for you 😉
I believe the flow is very self-explanatory. So I will not give any unnecessary explanation.
In fact, I would like to explain a bit, so that it can address everybody with all sorts of experience level.
Backend: As for backend, you can use framework you like (Laravel, Codeigniter, Node.js, Django...). For me, I like Node.js (I would recommend to use TypeScript instead of JS, it will protect you from doing silly mistakes).
Database: You can any database that suits your project. If you would use relations a lot, go for SQL (MySQL, PostgreSQL, MariaDB...), if you feel like you would need some freedom from schema and you will generate a tons of data (e.g IoT), go for NoSQL (MongoDB, ArangoDB, DynamoDB...). For caching, you can try Redis or memcached (When to cache? When you are querying same data over again, and the data does not change very frequently, e.g. number of github repo).
External API: In most of our projects, we happen to use some external API. Example would be, login with facebook/ google, talking to dialogflow/ twilio and so on. Keeping that written would help your team see the big picture.
Email Service: For signup, password recovery and so on, we need to use some sort of email service. I like sendGrid (because its simple and keeps records of all communications), but you can choose anything that works for you. (e.g. Nodemailer).
Testing: If you are working in a team, don't forget to follow Test Driven Development. TDD will enable you to write code fast and securely without having to worry about breaking functions/API. There are many libraries/ frameworks for TDD. Jasmine, mocha, chai, Jest and so on. My choice is Jest.
DevOps: You need a server to put your application. You can choose DigitalOcean, AWS EC2 or any other service. Most probably I would go for linux OS, but EC2 also allows you to have windows system. Then to serve the app, you need a web server. I like Nginx but you can go for Apache if you will. To run Node.js application, you need a process manager. For me, its PM2. Now you got your application running. But how to secure it? (https) You can buy a SSL certificate from a top provider or get a free one from letsEncrypy. As for version controlling, you can use git and github/gitlab/bitbucket as remote repo. If you want to automate the deploying process (CI/CD), you can use Jenkins or CircleCI.
Project Management: To keep track of the project and to make sure that your team is not falling behind the schedule, you need to have some sort of project management implemented. Since we need fast iteration, I would go for Agile management. Trello is a great tool to track your project. (Check this boilerplate to see how you can design a project on trello). For communication, slack is unbeatable. You can have different channels, direct message, document sharing and many more. It is more like a professional whatsApp. Finally, to make sure your team is doing well, arrange some code review sessions once a while. It could be weekly or sprint base. But this will make sure that you are having bad/ inefficient code.
I know it was long, but I think it would help you to have a better and organized plan.
Below is the github repo where you can find the editable file. Feel free to share your opinion. I wish you a very good day 👋