Programming

PiMP Ping-pong Management Platform

PiMP, also known as Ping-pong Management Platform is a one-stop solution to manage table-tennis matches in your organization. PiMP consists of a beautiful GUI accessible on your browser built with the latest technology stack. It helps manage your Players’ data, matches data, Tournaments, and even lets you scorekeeping the match in realtime. PiMP offers real-time […]

React MD v1 w/ Gatsby No!

Please avoid using ReactMD v1 with GatsbyJs, since ReactMD 2 is out with full rewrite, that could be an option if you want to stick with ReactMD. I had started to port this blog from WordPress to Gatsby and I had used React-MD ‘s Gatsby starter to start with the project. Because of issues in […]

ML5 with Webpack and TypeScript

Why TypeScript? TypeScript allows you to add static typing to your javascript, which adds a possibility to type check on your code during compile time. Even better your IDE itself will be able to tell you if there are any issues with your data types, etc in realtime. Additionally, it can be used by your […]

Docker compose update php.ini

How to configure the php.ini in your docker container On the root folder of your project where your docker-compose.yml is add a new file to replace some ini file in your PHP container. Then on your docker-compose.yml file add a volume to your PHP container volumes: -./your_local.ini:/etc/path/to/the/ini/you/want/to/replace/with.ini Then restart your docker container with –build flag […]

Machine Learning – On your Browser

Inviqa Engineering CoP 22.10.2020
Machine Learning on your Browser.

Gatsby with WordPress

Static site generation Why? When? How? Dynamic sites are slower, expensive, complex, hackable. When? If the site is mostly content and no heavy communication with server to update / calculate content in realtime. Best use case, Portfolio website, company website, blogs, etc. Static site generation with Gatsby Gatsby is powerful tool to create static sites […]

Javascript reduce function on array of objects

Array.reduce() function in javascript is one of the most interesting functions, but it may be tricky if you haven’t worked with it on array of objects. Let us first look at the following code (array of plain integers), the code basically sums up all the elements in the array: [js] [1, 2, 3].reduce((accumulator, element) => […]

Visual Studio Code: Customize find/search match highlight color

 To customize the highlight color of the find matches in visual studio code go to: File > Preferences > Settings > User Settings and add following to workbench.colorCustomizations and choose the colors. “workbench.colorCustomizations”: { “editor.findMatchBackground”:”#6f7700″, “editor.findMatchHighlightBackground”:”#833d03″ }

CSS targetting for IE 10+ excluding Edge

Use the following media query to target your css particularly for IE10+ browsers @media all and (min-width: 64em) and (-ms-high-contrast: none), (-ms-high-contrast: active) { /* IE10+ CSS styles go here */ }

Angular | Watch an object or an array

  $scope.$watch(‘objectOrArray’,function(newVal, oldVal){ // Do Something },true);  

Apache2 on Ubuntu ignores sites-enabled conf (vhost config)

I am using Vagrant to host my local dev environment in Ubuntu. I found this issue, Apache2 on Ubuntu ignores sites-enabled *.conf After few tries figured out, you need to edit the default 000-default.conf file and comment out the configurations there or just delete the file.

AngularJS problem : Links cant load page from server but uses ng-route

If you are using ng-route and want to load the page from your server you need to add target=”_self” to your anchor tag. Example: LINK

Arduino Development and Innovation in Nepal

WHAT IS ARDUINO? Arduino is an open-source electronics platform based on easy-to-use hardware and software. It’s intended for anyone making interactive projects. State of open source hardware development in Nepal Challenges and obstacles in development and innovation in Nepal What can be done to solve the issue of opensource hardware development and innovation in Nepal? […]

Paging a long text into a specific size document like pages using javascript

Here is a tutorial about creating  pages with specific height and width out of a very long text to give a microsoft word or other document editor type look using javascript and jQuery. 

Using gradient stops and transparency to dynamically fill circle partially in svg using d3js

Using gradient stops and transparency we can fill circle partially in svg. Doing this dynamically using data may be great visualization tool. We will use d3 to do this.

Create filled circle to visualize data using svg

Here is how to tutorial on creating filled circle to visualize data using svg and tiny bit of javascript.

An illegal choice has been detected in drupal select field|Bypass validation for ajax loaded options

Error : An illegal choice has been detected. Please contact the site administrator.

while trying to use ajax to load dynamic options in select field in drupal form api. Using Auto load on scroll of table select will give same error.

Drupal – Force Path Prefix for Default Language

When you have more than one language on Drupal site, you have to define the default language among one of them. For example, if i set English as the default language, it will be shown in both http:// and http:///en. but all the links in the default language will not have the en path prefix.