Using async/await with for loop in nodejs

Looping using for or foreach loop to read in sequence in nodejs async function printFiles () {   const files = await getFilePaths()   for (const file of files) {     const contents = await fs.readFile(file, 'utf8')     console.log(contents)   } } Looping using map function to read in parallel in nodejs async function printFiles () { const files = […]

Node, Express microservice with Swagger

In this article, we will discuss creating and testing a Node/Express microservice using Swagger.   Technologies node.js express.js swagger supertest   Installing swagger Before installing swagger for node.js, we need to make sure node and npm are installed. Check the same using following commands : node -v npm -v Now, we can install swagger using […]

Flutter – Convert String to int and int to String

Here is how to convert String to int and int to String in Flutter or Dart. String to int You can use int.parse(data) to convert String to int. Flutter String to int Example : main () {     var one = int.parse('1');     print(one == 1); // prints true }   Int to String You can use […]

How to change application launcher icon in Flutter

We can change the app launcher icon using following approaches : 1. Native approach to change launcher icon: Create the icons : You can either create the icons urself or use a website like https://appicon.co/   Changing app launcher icon for Android Replace the midmap* icons in android/app/arc/main/res folder with the generated ones in android […]

Flutter error – xcode_backend.sh: No such file or directory

Error message : xcode_backend.sh: No such file or directory Solution: xcode_backend.sh exists in flutter SDK location. In Project Target, add User-Defined Setting with key name¬†FLUTTER_ROOT¬†with the value of your flutter SDK location. Create FLUTTER_ROOT key in Runner -> Build Settings as follows : If you don’t remember where you have installed flutter sdk try this […]