Determining Whether Your Javascript Object is of Type X
There are times when you’re interested in knowing additional details about the Javascript Object that you’re handling, such as whether you’re handling an Array, Date, or standard Object. However, the typeof operator, when used against these different objects, returns the following results: console.log(typeof [1,2,
Jest Snapshot Testing With Dates and Times
Snapshot testing is great for quickly creating unit tests for components by getting a ‘snapshot’ of what a component looks like when it’s rendered on the page given certain prop values. This removes the need to manually check the amount of specific elements being rendered on the component, or