Author Archives: Ajitesh Kumar

Ajitesh Kumar

I have been recently working in the area of Data analytics including Data Science and Machine Learning / Deep Learning. I am also passionate about different technologies including programming languages such as Java/JEE, Javascript, Python, R, Julia, etc, and technologies such as Blockchain, mobile computing, cloud-native technologies, application security, cloud computing platforms, big data, etc. I would love to connect with you on Linkedin. Check out my latest book titled as First Principles Thinking: Building winning products using first principles thinking.

AngularJS – 10 Best Practices to Create Custom Directives

best_practices_angularjs_directives

This article represents top 10 best practices that one may want to apply while creating custom directives. Please feel free to comment/suggest if I missed to mention one or more important points. Also, sorry for the typos. Following is listed the best practices for creating custom directives: Naming Convention: Prefer using two or three letter prefix (except ng) while naming directives to avoid collision with future HTML releases. Using “ng” as prefix might collide with AngularJS OOTB directives in future. Directive Definition Object (DDO): Prefer returning DDO rather than a function. TemplateUrl Usage: Prefer storing HTML template code in a seperate file and assign the path to templateUrl variable. Attribute …

Continue reading

Posted in Javascript, Web. Tagged with .

How to Setup Eclipse IDE for Sonar Analysis

This article describes steps required to configure your eclipse for SonarQube such that developers are not required to leave the eclipse IDE to manage their source code quality. Please feel free to comment/suggest if I missed to mention one or more important points. Also, sorry for the typos. Following are the key points described later in this article: Installing & Configuraing SonarQube in Eclipse Analyzing code using SonarQube Installing & Configuring SonarQube in Eclipse Follow the steps given on following pages to install and configure SonarQube in your Eclipse IDE. The page on Installing SonarQube in Eclipse consists of steps required to install SonarQube in the IDE. Once downloaded, it …

Continue reading

Posted in Software Engg, Software Quality. Tagged with .

How to Quickly Get Started with Sonar

get_started_with_sonar

This article represents steps required to quickly get up and running with Sonar and keep it handy for your personal Java/.NET/PHP etc related projects. Please feel free to comment/suggest if I missed to mention one or more important points. Also, sorry for the typos. Following are the key points described later in this article: Sonar setup instructions Configure HelloWorld Project for Code Analysis Sonar setup instructions Following are two key aspects of getting Sonar and dependencies installed, configured and setup for usage. Installation of SonarQube Installation of Code Analyzer Installation of SonarQube Following is instruction-set to get setup with SonarQube: Go to Sonar community edition page and download. Unzip the …

Continue reading

Posted in Software Quality. Tagged with .

AngularJS – Non-nested Directive-to-Directive Communication – Code Example

non nested directives communication

This article presents concepts and code example around non-nested directives-to-directives communication in AngularJS. The demo for the code example presented later in this article can be accessed on this page, Demo – Non-nested Directives-to-Directives Communication. Please feel free to comment/suggest if I missed to mention one or more important points. Also, sorry for the typos.   Following are the key points described later in this article: What is Directive-to-Directive Communication? Service Helps Directives Communicate Code Example – Non-nested Directives Communication   What is Directive-to-Directive Communication? When the change in one or more attributes of one directive need to trigger one or more events in other directives resulting in updating of their …

Continue reading

Posted in Javascript. Tagged with .

AngularJS QuizApp Framework on Github

quizapp

This article describes the QuizApp web application written with AngularJS & Bootstrap that I open-sourced it today on GitHub. Here is the link for the QuizApp Project Homepage for you to get started. I have made use of this app in my other website, Free Online Tests and trust me, creating quizzes is so very smooth experience. The primary reason why I decided to make it open-source is the fact that there are several requests that I received in the past for posting the source code. However, as I created the app for my personal usage, I went ahead and modified it suitably for easy re-use. Please feel free to suggest …

Continue reading

Posted in Javascript, Tools, UI. Tagged with .

Top 10 PHP Code Review Tips

php_code_review_best_practices

This article represents top 10 areas to consider while you are taking up the task to do the code review of a PHP project. The other day, I had a discussion with one of the PHP senior developers who asked me about where to start on the task related with reviewing a PHP web application and, we brainstormed and came up with the list. Interestingly, apart from few, most of them can be pretty much applied to applications written with other programming languages as well. Please feel free to comment/suggest if I missed to mention one or more important points. Also, sorry for the typos. Following are the key points described later …

Continue reading

Posted in PHP, Software Quality. Tagged with , .

AngularJS – Why & How to Create Custom Module

angularjs custom module

This article represents key concepts and code samples on why and how to create a custom module with AngularJS. Please feel free to comment/suggest if I missed to mention one or more important points. Also, sorry for the typos.   Following are the key points described later in this article: Why create a custom module? How to create a custom module?   Why Create A Custom Module? A module in AngularJS wires together some of the following components: Controllers Directives Filters Service   In simple words, a module could also be thought of as container of above components. As per the design, if there is a need to bundle together …

Continue reading

Posted in Javascript, UI. Tagged with .

How to Start a Big Data Practice

This article represents key aspects of starting up Big Data practice in your organization. Currently, I have started working in the same area and this blog is the result of my research. Hope you find it useful. Please feel free to comment/suggest if I missed to mention one or more important points. Also, sorry for the typos.   Big Data Center of Excellence (COE) It may be a good idea to plan around setting up a Big Data Center of Excellence (COE)whose main objective would be take a holistic approach towards following two key aspects of Big Data from different perspectives such as setting up team, evaluating tools & frameworks, …

Continue reading

Posted in Big Data. Tagged with .

Why JSFiddle is a Great Tool for Web Technologies Blogger

jsfiddle for blogging

This article describes reasons on why jsfiddle could prove to be a great tool for Web Technologies Blogger. I have been doing active blogging on Web technologies including HTML/JS/CSS. After coming across JSFiddle and playing with it for a while, I believe JSFiddle could serve as a great productivity tool for blogging on web technologies. I have listed some of the reasons below. Please feel free to comment/suggest if I missed to mention one or more important points. Also, sorry for the typos.   Following are the key reasons explained later in this article: Allow users to play with your code Get rid of Boilerplate HTML/JS/CSS Code Easy to embed in …

Continue reading

Posted in Tools. Tagged with , , .

AngularJS – How to Create a Custom Filter – Code Example

This article represents high level concepts and code sample/example for how to create a custom filter. The demo for the code example given below could be found on this following page: How to Create A Custom Filter. Please feel free to comment/suggest if I missed to mention one or more important points. Also, sorry for the typos.   Following are the key points described later in this article: Key aspects of creating a custom filter Code Samples – Custom Filter   Key Aspects of Creating Custom Filter Following are some of the key aspects that one needs to pay attention to, while creating a custom filter: To create a new filter, …

Continue reading

Posted in Javascript, UI. Tagged with .

AngularJS Directives Hello World – Code Example

angularjs

This article represents high level concepts and code examples on how to create a custom directive. For detailed documentation, one could access AngularJS page on custom directive. You could check out live demo of the code example in this article on http://hello-angularjs.appspot.com/angularjs-directives-hello-world Please feel free to comment/suggest if I missed to mention one or more important points. Also, sorry for the typos.   Following are the key points described later in this article: Key aspects of Directive Code Examples – Directives Hello World   Key Aspects of Directive The directive discussed in the blog is following: <hello name=”Calvin Hobbes”></hello> Following are some of the key aspects: Define directive. In this …

Continue reading

Posted in Javascript, UI. Tagged with .

Ionic Framework – Different Ways to Create List

This article represents code samples and tips to create list items in hybrid apps created using Ionic framework. Please feel free to comment/suggest if I missed to mention one or more important points. Also, sorry for the typos.   Following are the key techniques described later in this article: List items created using AngularJS custom directive, Ion-List (Recommended way) List items created using ul element List items created using div The code sample below demonstrate how URLs with its name and hyperlink is stored as array in AngularJS scope and later accessed in the view with ng-repeat directive. .controller(‘HelloCtrl’, [‘$scope’, function($scope){ $scope.urls = [{‘name’:’Gmail’,’url’:’http://www.gmail.com’}, {‘name’:’Yahoo Mail’, ‘url’:’http://mail.yahoo.com’}, {‘name’:’Hotmail’, ‘url’:’http://www.hotmail.com’}]; }]) …

Continue reading

Posted in Mobility. Tagged with , .

Sublime – AngularJS – Useful Auto-complete Snippets

angularjs sublime text editor

This article presents code samples and instructions to configure your Sublime editor to include ng (angular) scripts in auto-complete fashion. I found it important to get quickly started with my new angular apps. Based on following, you could define custom autocomplete snippets for all angular scripts.   Following are the steps to create snippet file for each angularjs script: In Sublime Text Editor, go to Tools > New Snippet. A new untitled file consisting of following code would open: <snippet> <content><![CDATA[ Hello, ${1:this} is a ${2:snippet}. ]]></content> <!– Optional: Set a tabTrigger to define how to trigger the snippet –> <!– <tabTrigger>hello</tabTrigger> –> <!– Optional: Set a scope to limit …

Continue reading

Posted in Javascript, Tools, UI. Tagged with , .

Sublime – Configure to Open HTML Page in a Web Browser

This article presents steps that is needed to configure Sublime to open the HTML pages you are working, in your preferred web browser. As I started developing AngularJS apps with Sublime, I got stuck at the point where I have to manually go to appropriate folder consisting of HTML file and double-click to open it in browser or, go to existing browser having that page and refresh it. In both the case, it was quite a bit cumbersome. Ideally, I wanted some shortcut keys right from within Sublime which would have helped me open the file in browser. This is where I did some research and found the way out. …

Continue reading

Posted in Tools. Tagged with .

AngularJS – How to Code Quickly with Sublime Text Editor

angularjs sublime text editor

After working on AngularJS for sometime now, I was looking for an editor which helps to code efficiently and effectively with AngularJS. This is when I discovered Sublime Text Editor. This article presents tips on what needs to be done to write AngularJS code with Sublime Text Editor. I have to confess that it has been a fulfilling experience to code in AngularJS with Sublime once installation and configuration is done. I was able to complete my AngularJS hello world program within few minutes. Trust me, it is worth your time. Let me know what you think about it. Do the following and enjoy the Angular ride much more than ever: …

Continue reading

Posted in Javascript. Tagged with .

Ionic Framework Hello World – Code Example

ionic framework

This article helps you get started with Ionic Framework, the open-source front-end framework for developing hybrid mobile apps with HTML5. Following will be discussed in the article: Why Ionic Framework? Pre-requisite for Good Fun with Ionic Ionic framework installation Ionic Starter Projects Hello World code example Feel free to add/suggest any points that I may have missed upon.   Why Ionic Framework? When you have frameworks like Cordova/PhoneGap or Titanium, why need Ionic in the first place? Well, as I get started with some of these frameworks and got done with Hello World program and wanted to do more, I decided on getting myself expert at developing hybrid apps. The …

Continue reading

Posted in Mobility. Tagged with , .