In this post, we are going to learn the observer pattern and the usage of this design pattern.
According to the GoF definition, observer pattern defines a one-to-many dependency between objects so that when one object changes state, all its dependents are notified and updated automatically. It is also referred to as the publish-subscribe pattern.
In simple words when you want to be aware of changes in another object probably you can use Observer Design Pattern.
The observer design pattern is a behavioral pattern and it means it is a pattern of communication between objects.
Other names of this design…
This is a summary of a few articles that you can find in the reference part.
Use CI tools to check If tests are passing and the app can be built before starting the review process.
Using these tools can save a lot of time. These tools can highlight changes and also you are able to interact with the developer or reviewer using these tools.
The developer should annotate their source code before the review process. By having the authors carefully read through…
A few days ago I wanted to test the authentication using LinkedIn and there was no straight forward article to help me. So I decided to note down the steps in this article and I hope it would be helpful.
LinkedIn can be one of the Identity Providers of your application. We have seen this in lots of websites that let us login with our Google Account, Facebook account, or Github and LinkedIn. We want to do the same and let the user sign in with his/her LinkedIn account.
A load test is a type of software testing which is conducted to understand the behavior of the application under a specific expected load. Load testing is performed to determine a system’s behavior under both normal and at peak conditions(reference).
If you are not familiar with this type of test you should know that we always want to know the capability of our software and the number of online users that we can handle. …
It is a structural design pattern that lets you attach new behaviors to objects by placing these objects inside special wrapper objects that contain the behaviors (reference).
When we are using Typescript Method Decorators, they are higher-order functions that help us change method behavior or do something with the arguments.
Typescript method decorator definition: method decorator can be used to observe, modify, or replace a method definition (reference)
Now, let’s see how we can define a simple method decorator.
In order to run the Typescript code, we need to compile them using the Typescript compiler.
We need a
Based on their website:
deno info) and a code formatter (
Deno is created by Ryan Dahl and he…
“ Integration tests determine if independently developed units of software work correctly when they are connected to each other. The term has become blurred even by the diffuse standards of the software industry, so I’ve been wary of using it in my writing. In particular, many people assume integration tests are necessarily broad in scope, while they can be more effectively done with a narrower scope. “ Martin Fowler.
We can use this feature when we have nested functions like this:
Streams are a collection of data that might not be complete and we might not fit them in memory.
When we watch an online video we use a stream. Do we need to download the whole video to watch it? the answer is no. thus the video data is not complete but we can watch the parts we want!
Imagine we are uploading a video with 12GB size. The problem is our memory is only 4GB. So how is it possible to upload such a file? …
console.log as a debugger!)
This is the file:
Full Stack Developer at Telewebion.