Tech Stack I used to Build neetcode.io

NeetCodeIO · Intermediate ·⚡ Algorithms & Data Structures ·2y ago

Key Takeaways

The NeetCodeIO tech stack consists of Angular 14, Bulma, Firebase, and Judge0, with a TypeScript backend and Stripe for payments.

Full Transcript

people always ask me like how I made this like what's the text stack for this okay so the neat code text stack is pretty simple to be honest I try to keep it simple one is angular and it's actually angular 14 now there's angular 17 I probably should upgrade at some point CU they made a lot of improvements but I'm too lazy to do that so for now we're on angular 14 another one for CSS I don't actually have like a UI Library I don't have a components Library I'm writing all my CSS but I also have a library for like a little bit of stuff called Bulma why angular it's scary that's just what I know cuz I'm a big boy we don't play around with Kitty tools like react or nextjs okay I'm just kidding mostly for the back end and people make fun of me for this but it is what it is I use Firebase stuff on the back end so that includes Firebase function so this is basically like my rest API layer functions the other thing is fire store this is my nosql database why a nosql database just because it comes with Firebase if it was up to me I would rather actually use a relational database but it is what it is third for authentication I use Firebase o because why would I use o zero when I have to pay for that why would I use next o when I have to pay for that I'm just going to use Firebase o it's been almost two years of me running this and it's been completely free and it works so why would I pay for it I think that's pretty much it for the Firebase side yeah and all of this is done in a typescript back end again why because typescript I think is the language that just has the most support for Firebase functions Firebase trash but it works call it what you want oh you used Firebase that's cheating what do you want me to do what do you want me to do make my own rest API and then post it on a VM why would I do do that when I can just have functions that scale and to be honest in my case I do kind of need a little bit of scaling when I first started it I probably could have just used a single VM for all my functions at this point I probably need like three or four and I haven't had to do any redeployments or anything I run one command Firebase deploy and it just deploys the functions so why would I do anything more complicated than that why would I self-host my own database even if I was going to use a relational database I'd probably use like a SQL managed database in Google cloud or another platform maybe like Planet scale why would I want to manage my own database why would I want to implement my own authentication maybe to save money but in my case I don't need it if I wanted to add another provider right now I have Google and I have GitHub if I wanted to add another provider it's literally one line of code I'll show it to you look log in with Google just all I have to do is log in with the provider pass in the Google off provider Constructor log in in with GitHub pass in Google off provider if I want to add another one let's say log in with Facebook this is how I do it log in Facebook co-pilot knows how to do it for me because this is the easiest code you're going to write in your life that's it now now we can log in with Facebook so tell me why would I implement this from scratch why would I want to do that people can laugh but it works the other thing I am using judge zero for code execution to actually execute this code I did need more than Firebase uh function so that's like the down inside of Firebase functions like a Firebase function will start and execute and after like let's say 2 seconds it kills itself but I needed something that runs indefinitely to run judge zero so for that I actually did need a virtual machine so I got that from Google Cloud do you use Docker also technically judge zero uses Docker so when I SSH into that VM I'm running like Docker compose believe it or not yeah so that starts up all the docker containers that this needs and then I'm good to to go and obviously I wouldn't want to publicly expose judge zero I don't want anybody to be able to send their code so what I do is from the client a user sends their code to Firebase and then Firebase functions will authenticate is that user authenticated do they have access to this problem and then from there I'll send the code to judge zero for payments I'm using stripe which I haven't had any problems with it this judge zero kind of like kubernetes it starts up like four docker containers so it's not like kubernetes it's like a program somebody wrote it's actually not as much code as you would think people think creating like a code sandbox like this is a lot of work and I'm sure it is that's why I didn't write my own but when you actually look at the source code and for all you open source people who want to like start working on open source you got to get good at one thing and it's reading code reading code is more important than writing code and you don't really learn that in school but when you go through this they even mention it somewhere I read through the source code and I won't do it right now but you'll find U mentions of isolate and what that actually does that takes a lot of the work out of creating a code judge because the hardest part is the security aspect of it if you're sending arbitrary code to your backend you don't want it to like do anything crazy there's a command line tool it's open source it's called isolate and it's used to sandbox executing untrusted programs so judge zero heavily makes use of this open source CL tool and that takes most of the work out so if I was going to code my own code judge I'd just use this tool now judge zero does do a lot like it installs all the compilers all the runtime environments and it like does a lot of stuff I don't know why dredge zero needs a database though but it does and there's a lot of other things about it but you can read through this code there's not a ton it's written in Ruby though which I'm not super familiar with but you can still kind of understand it if I was going to add like additional stuff to this I'd probably just Fork this which I technically did rather than create my own

Original Description

🚀 https://neetcode.io/ - A better way to prepare for Coding Interviews 🧑‍💼 LinkedIn: https://www.linkedin.com/in/navdeep-singh-3aaa14161/ 🥷 Discord: https://discord.gg/ddjKRXPqtk 🐦 Twitter: https://twitter.com/neetcode1 🐮 Support the channel: https://www.patreon.com/NEETcode ⭐ BLIND-75 PLAYLIST: https://www.youtube.com/watch?v=KLlXCFG5TnA&list=PLot-Xpze53ldVwtstag2TL4HQhAnC8ATf 💡 DYNAMIC PROGRAMMING PLAYLIST: https://www.youtube.com/watch?v=73r3KWiEvyk&list=PLot-Xpze53lcvx_tjrr_m2lgD2NsRHlNO&index=1 #neetcode #leetcode #python
Watch on YouTube ↗ (saves to browser)
Sign in to unlock AI tutor explanation · ⚡30

Playlist

Uploads from NeetCodeIO · NeetCodeIO · 0 of 60

← Previous Next →
1 Leetcode 149 - Maximum Points on a Line - Python
Leetcode 149 - Maximum Points on a Line - Python
NeetCodeIO
2 Design Linked List - Leetcode 707 - Python
Design Linked List - Leetcode 707 - Python
NeetCodeIO
3 Minimum Time to Collect All Apples in a Tree - Leetcode 1443 - Python
Minimum Time to Collect All Apples in a Tree - Leetcode 1443 - Python
NeetCodeIO
4 Design Browser History - Leetcode 1472 - Python
Design Browser History - Leetcode 1472 - Python
NeetCodeIO
5 Number of Good Paths - Leetcode 2421 - Python
Number of Good Paths - Leetcode 2421 - Python
NeetCodeIO
6 Flip String to Monotone Increasing - Leetcode 926 - Python
Flip String to Monotone Increasing - Leetcode 926 - Python
NeetCodeIO
7 Maximum Sum Circular Subarray - Leetcode 918 - Python
Maximum Sum Circular Subarray - Leetcode 918 - Python
NeetCodeIO
8 Find Closest Node to Given Two Nodes - Leetcode 2359 - Python
Find Closest Node to Given Two Nodes - Leetcode 2359 - Python
NeetCodeIO
9 Concatenated Words - Leetcode 472 - Python
Concatenated Words - Leetcode 472 - Python
NeetCodeIO
10 Data Stream as Disjoint Intervals - Leetcode 352 - Python
Data Stream as Disjoint Intervals - Leetcode 352 - Python
NeetCodeIO
11 LFU Cache - Leetcode 460 - Python
LFU Cache - Leetcode 460 - Python
NeetCodeIO
12 N-th Tribonacci Number - Leetcode 1137
N-th Tribonacci Number - Leetcode 1137
NeetCodeIO
13 Best Team with no Conflicts - Leetcode 1626 - Python
Best Team with no Conflicts - Leetcode 1626 - Python
NeetCodeIO
14 Greatest Common Divisor of Strings - Leetcode 1071 - Python
Greatest Common Divisor of Strings - Leetcode 1071 - Python
NeetCodeIO
15 Shortest Path in a Binary Matrix - Leetcode 1091 - Python
Shortest Path in a Binary Matrix - Leetcode 1091 - Python
NeetCodeIO
16 Insert into a Binary Search Tree - Leetcode 701 - Python
Insert into a Binary Search Tree - Leetcode 701 - Python
NeetCodeIO
17 Delete Node in a BST - Leetcode 450 - Python
Delete Node in a BST - Leetcode 450 - Python
NeetCodeIO
18 Shuffle the Array (Constant Space) - Leetcode 1470 - Python
Shuffle the Array (Constant Space) - Leetcode 1470 - Python
NeetCodeIO
19 Fruits into Basket - Leetcode 904 - Python
Fruits into Basket - Leetcode 904 - Python
NeetCodeIO
20 Number of Subarrays of size K and Average Greater than or Equal to Threshold - Leetcode 1343 Python
Number of Subarrays of size K and Average Greater than or Equal to Threshold - Leetcode 1343 Python
NeetCodeIO
21 Naming a Company - Leetcode 2306 - Python
Naming a Company - Leetcode 2306 - Python
NeetCodeIO
22 As Far from Land as Possible - Leetcode 1162 - Python
As Far from Land as Possible - Leetcode 1162 - Python
NeetCodeIO
23 Shortest Path with Alternating Colors - Leetcode 1129 - Python
Shortest Path with Alternating Colors - Leetcode 1129 - Python
NeetCodeIO
24 Minimum Fuel Cost to Report to the Capital - Leetcode 2477 - Python
Minimum Fuel Cost to Report to the Capital - Leetcode 2477 - Python
NeetCodeIO
25 Count Odd Numbers in an Interval Range - Leetcode 1523 - Python
Count Odd Numbers in an Interval Range - Leetcode 1523 - Python
NeetCodeIO
26 Contains Duplicate II - Leetcode 219 - Python
Contains Duplicate II - Leetcode 219 - Python
NeetCodeIO
27 Path with Maximum Probability - Leetcode 1514 - Python
Path with Maximum Probability - Leetcode 1514 - Python
NeetCodeIO
28 Add to Array-Form of Integer - Leetcode 989 - Python
Add to Array-Form of Integer - Leetcode 989 - Python
NeetCodeIO
29 Unique Paths II - Leetcode 63 - Python
Unique Paths II - Leetcode 63 - Python
NeetCodeIO
30 Minimum Distance between BST Nodes - Leetcode 783 - Python
Minimum Distance between BST Nodes - Leetcode 783 - Python
NeetCodeIO
31 Design Hashmap - Leetcode 706 - Python
Design Hashmap - Leetcode 706 - Python
NeetCodeIO
32 Range Sum Query Immutable - Leetcode 303 - Python
Range Sum Query Immutable - Leetcode 303 - Python
NeetCodeIO
33 Binary Tree Zigzag Level Order Traversal - Leetcode 103 - Python
Binary Tree Zigzag Level Order Traversal - Leetcode 103 - Python
NeetCodeIO
34 Middle of the Linked List - Leetcode 876 - Python
Middle of the Linked List - Leetcode 876 - Python
NeetCodeIO
35 Course Schedule IV - Leetcode 1462 - Python
Course Schedule IV - Leetcode 1462 - Python
NeetCodeIO
36 Single Element in a Sorted Array - Leetcode 540 - Python
Single Element in a Sorted Array - Leetcode 540 - Python
NeetCodeIO
37 Capacity to Ship Packages - Leetcode 1011 - Python
Capacity to Ship Packages - Leetcode 1011 - Python
NeetCodeIO
38 IPO - Leetcode 502 - Python
IPO - Leetcode 502 - Python
NeetCodeIO
39 Minimize Deviation in Array - Leetcode 1675 - Python
Minimize Deviation in Array - Leetcode 1675 - Python
NeetCodeIO
40 Longest Turbulent Array - Leetcode 978 - Python
Longest Turbulent Array - Leetcode 978 - Python
NeetCodeIO
41 Last Stone Weight II - Leetcode 1049 - Python
Last Stone Weight II - Leetcode 1049 - Python
NeetCodeIO
42 Construct Quad Tree - Leetcode 427 - Python
Construct Quad Tree - Leetcode 427 - Python
NeetCodeIO
43 Find Duplicate Subtrees - Leetcode 652 - Python
Find Duplicate Subtrees - Leetcode 652 - Python
NeetCodeIO
44 Sort an Array - Leetcode 912 - Python
Sort an Array - Leetcode 912 - Python
NeetCodeIO
45 Ones and Zeroes - Leetcode 474 - Python
Ones and Zeroes - Leetcode 474 - Python
NeetCodeIO
46 Remove Duplicates from Sorted Array II - Leetcode 80 - Python
Remove Duplicates from Sorted Array II - Leetcode 80 - Python
NeetCodeIO
47 Maximum Twin Sum of a Linked List - Leetcode 2130 - Python
Maximum Twin Sum of a Linked List - Leetcode 2130 - Python
NeetCodeIO
48 Concatenation of Array - Leetcode 1929 - Python
Concatenation of Array - Leetcode 1929 - Python
NeetCodeIO
49 Symmetric Tree - Leetcode 101 - Python
Symmetric Tree - Leetcode 101 - Python
NeetCodeIO
50 Check Completeness of a Binary Tree - Leetcode 958 - Python
Check Completeness of a Binary Tree - Leetcode 958 - Python
NeetCodeIO
51 Construct Binary Tree from Inorder and Postorder Traversal - Leetcode 106 - Python
Construct Binary Tree from Inorder and Postorder Traversal - Leetcode 106 - Python
NeetCodeIO
52 Find Peak Element - Leetcode 162 - Python
Find Peak Element - Leetcode 162 - Python
NeetCodeIO
53 Accounts Merge - Leetcode 721 - Python
Accounts Merge - Leetcode 721 - Python
NeetCodeIO
54 Binary Tree Preorder Traversal (Iterative) - Leetcode 144 - Python
Binary Tree Preorder Traversal (Iterative) - Leetcode 144 - Python
NeetCodeIO
55 Binary Tree Postorder Traversal (Iterative) - Leetcode 145 - Python
Binary Tree Postorder Traversal (Iterative) - Leetcode 145 - Python
NeetCodeIO
56 Number of Zero-Filled Subarrays - Leetcode 2348 - Python
Number of Zero-Filled Subarrays - Leetcode 2348 - Python
NeetCodeIO
57 Minimum Score of a Path Between Two Cities - Leetcode 2492 - Python
Minimum Score of a Path Between Two Cities - Leetcode 2492 - Python
NeetCodeIO
58 Sqrt(x) - Leetcode 69 - Python
Sqrt(x) - Leetcode 69 - Python
NeetCodeIO
59 Successful Pairs of Spells and Potions - Leetcode 2300 - Python
Successful Pairs of Spells and Potions - Leetcode 2300 - Python
NeetCodeIO
60 Optimal Partition of String - Leetcode 2405 - Python
Optimal Partition of String - Leetcode 2405 - Python
NeetCodeIO

The NeetCodeIO tech stack is a combination of Angular 14, Bulma, Firebase, and Judge0, with a TypeScript backend and Stripe for payments. This tech stack allows for a scalable and secure web application with a simple and efficient backend.

Key Takeaways
  1. Choose a suitable frontend framework like Angular 14
  2. Implement a CSS library like Bulma
  3. Use a cloud provider like Firebase for backend logic and authentication
  4. Implement a payment gateway like Stripe
  5. Use a sandboxing tool like Isolate for security
  6. Deploy the application to a cloud platform like Google Cloud
💡 Using a cloud provider like Firebase and a sandboxing tool like Isolate can simplify the development and deployment of a web application, while also ensuring security and scalability.

Related Reads

📰
O(N) Manacher's Algorithm with Mirror Boundary Optimization
Learn to optimize palindrome detection using Manacher's Algorithm with mirror boundary optimization, reducing time complexity to O(N)
Dev.to · Dipaditya Das
📰
Building a Power Grid Inside Minecraft with BFS Algorithms
Learn to build a power grid inside Minecraft using BFS algorithms and understand its relevance to cloud services
Dev.to · Carlos Cortez 🇵🇪 [AWS Hero]
📰
The Run-Length Encoding Trick: How Simple Strings Get Compressed
Learn how Run-Length Encoding (RLE) compresses simple strings, a fundamental technique in programming and data compression, and apply it to optimize storage and transmission of data
Medium · Programming
📰
75 Days of Leetcode — Day 4: #238 — Product of Array Except Self
Solve the Product of Array Except Self problem on LeetCode to improve coding skills and learn array manipulation techniques
Medium · AI
Up next
Stump Grinder Carbide Wheel Grinds Hardwood To Chips
Innoforge Studio
Watch →