Recently, I started learning Test Driven Development, (TDD). True to its name, this means tests are written before any functional code is written. At most, a shell version of the code is written so that the tests can call it, but the code should not be functional until the test is written.
Tests should always fail before any real code is written. You should be suspicious if they are not! Otherwise, you can’t be sure that your tests are actually catching any errors.
My final project for Flatiron was a budgeting tool, where users can create budgets by category and month and analyze them against their expenses. I’d have preferred to have done this with live transactions using the Plaid API, but unfortunately there wasn’t a ton of documentation for Ruby on Rails, which is the backend I was using. With 1.5 weeks to complete the project, I ended up creating my own list of transactions.
Having a financial background and an interest in fintech, I was determined to figure out the Plaid API after graduation. I had to decide whether I wanted…
When I was doing some research for a project I’m working on, I stumbled on the async/await syntax, which is the ES2017 way or writing a promise based fetch call. At Flatiron, had been taught using plain promises, although some of my classmates taught themselves async/await.
Async/await is syntactic sugar written on top of promises. It makes asynchronous code appear more synchronous. Below, I’ll show how to refactor a regular promise to async/await.
As a refresher — whenever we make a request with fetch, it returns a promise. …
Until recently, I only knew how to use reduce for its most common purpose — to sum up all elements in an array. I knew it was capable of more, but only dove into its many uses when I started preparing for technical interviews.
It’s worth understanding the intricacies to use it to not only sum values, but to flatten arrays, sum the values in an array of objects, and even reverse a string.
Reduce, like map and filter, is a higher order function. A higher order function is a function that receives a function as an argument or returns…
We’re currently winding down Mod4 at the Flatiron school, which means that our job search will start in a little over three weeks. Many of us, myself included, only learned how to code this year by doing pre-work in the spring and starting bootcamp in the summer. The idea that I can go out into the world this fall and get paid for my new skills seems crazy to me — I feel far from an expert in my field.
Although it’s true that I know the basics for a career in software engineering, and I wonder if I’ll ever…
I am somebody who likes to have a list: be it a to-do list, a shopping list, a packing list. If it’s not fully written down, there is a high chance I will get distracted, come back to it, and probably not do it quite as well. It is no different when I have to map out associations between my models in Ruby. When I slow down and map out every detail before I create my tables and my models, I have a much better outcome.
If you are a beginner, I recommend you get into this habit as soon…
Full stack developer based in Brooklyn, NY