Skip to main content

Posts

How to get started with mobile app?

Are you new to mobile development and wondering where to get started in this saturated and complex world of frameworks? Are you wondering whether to go native, hybrid or new kid on the block: PWA ? I would suggest don't waste any time and just get your hands dirty.... When I started looking at mobile development, I went through the same experience. So to save you the time, I would suggest start with Ionic framework to start building Hybrid apps. You should be comfortable with HTML, JavaScript, some CSS and some Angular (SPA framework) knowledge would help but you can learn this as you go along. You can get started with Ionic in 3 simple steps . You can test you app locally in your browser or on your device using DevApp That's all you need to get started!!! Your career as mobile developer started in under 10 mins!! Happy development. Feel free to share any more similar frameworks in comments below. 

What is Event Sourcing?

If you scratching your head and wondering what is Event Sourcing, this is a very good article to start. https://www.erikheemskerk.nl/event-sourcing-awesome-powerful-different/ I couldn't have explained it any better.

Overcoming CORS while testing SPA locally

One of the common problems you common across while developing SPA or hybrid mobile apps locally is that when you make a cross domain API call, this is what you get in your console window XMLHttpRequest cannot load http://jsonplaceholder.typicode.com/. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:8100' is therefore not allowed access.  The reason for this is the browser security is preventing cross domain Ajax call. You can read more about CORS here . As a developer you don't want to worry about this and you just want to drink your coffee, write awesome code and test it your machine. Cool! I do the same! Here is a little secret. You can tell Chrome to ignore the security and allow cross domain request. To do this, create a new shortcut for Chrome and pass these parameters.   --disable-web-security --user-Agent="Android" --user-data-dir="c:/temp-chrome-eng" user-Agent is opt...

Why there is semicolon at the start of a JavaScript function?

Very often while reviewing the code for my team, I will come across a semicolon at the start of JavaScript function as show below ; (function () { 'use strict'; ...and I often wondered what purpose it served. Guess what. It is an insurance to make sure your script works fine when all other scripts are merged together;  The leading ; in front of immediately-invoked function expressions (iffe) is there to prevent errors when appending the file during concatenation to a file containing an expression not properly terminated with a ;. So there you go. Now you know what that little semicolon is doing there in your code.

How to handle different namespace between serialization and deserialization

Consider this scenario: You have a web service with entries in a namespace Company.Business.Entities You have matching entities on the client side in a namespace Company.Client.Entities You want to simply serialize the Business Entity, transfer over the wire and deserialize  into client enetites. Problem!!!! you can't as the namespace is not same. Solution Put a namespace attribute on each client side and server side entity. e.g. [ DataContract (Namespace  =   "http://wwww.yourcompany.com/messages/entities" )] The problem with this is that you will have to add this to each and every entity.     2. Option 2 and probably better is to use assembly attribute in assemblyinfo.cs [ assembly :  ContractNamespace ( "http:// wwww.yourcompany.com/messages/entities " , ClrNamespace  =   "Company.Client.Entities" )] Add this to both, client and Business entities. Remember to update ClrNamespace and runtime will create corr...

How not to do Stand ups?

So what is a stand up in a Scrum? A stand up is basically a Scrum event, where the whole Scrum team gets together each morning to answer three questions: 1. What I did yesterday? 2. What I am working on today? 3. Are there any impediments? That's it! Team will usually stand up in a circle, if possible near the Kanban board. So what are the things that can go wrong here? Most of the teams replace project meetings with stand up and these often become lengthy discussion meetings. The team start discussing issues, design solutions, weather, coffee from the machine, pets etc..... The team looks and reports to the Scrum Master or team lead. Often the team see this a status reporting meeting. The time and place of  the stand up keeps changing. If the Scrum Master is not available, the team is lost on who will conduct the stand up and whom to report to. So what can we do to address this? The Scrum Master should coach the team to stick to above three questions. The...

10 things Scrum team should do

Here is a list of 10 things a scrum team should do. These are in no particular order 1. Keep to the time in all scrum events e.g daily stand-up, sprint planning and retrospective 2. Keep focus on the sprint goal. Everything else is secondary including personal opinion and egos. 3. Keep task and burn down chart up to date. 4. Regular communication and collaborations. Don't let the tools of communication replace one to one communication. At times it is easy just to walk to someone's desk and ask a question. 5. Where possible, sit close to each other. 6. Finish all the task on a story and mark it Done Done before picking a new one. 7. Have regular team outing like lunch or pub for team bonding. A scrum team goes through a process for forming, storming and norming. Any team events helps to get to norming stage early. 8. Have respect for all team members. Agree a protocol for Do not disturb and stick to it for e.g. if I have my headphones on, please do not disturb me unles...

Immediately Executable Functional Expression - IEFE or iffy

IEFE or iffy is a JavaScript function that, as the name says, is executed immediately. Here is the syntax. The key is the brackets at the start and end of function. This helps to keep the scope of the variables within the function. Without the function workerProcess and worker will have global scope which is BAD!!! (function () {     var workerProcess = function () {         var task1 = function () {             console.log("task 1");         };         var task2 = function () {             console.log("task 2");         };         return {             job1: task1,             job2: task2         };     };     var worker = workerProcess();     worker.job1();     worker.job2(); ...