Skip to content
Sandny Blog
  • Home
  • Java
  • JavaScript
  • AWS
  • Embedded
  • About
SSL Websocket using Nginx Proxy Express.js

SSL Websocket proxy with Nginx for Graphql Subscriptions

  • May 12, 2022May 12, 2022
  • by Coder Kai

GraphQL has become the most used API framework to use in mobile and web platforms. Often we come with instances where we need to run these services behind a proxy server like Nginx to co-exist with other services. In this tutorial, you will find how to configure your SSL certs with the WebSocket server in order to

Read more “SSL Websocket proxy with Nginx for Graphql Subscriptions” →
Change python version correctly JavaScript

Python is not setting correct path in mac os

  • December 18, 2021December 18, 2021
  • by Coder Kai

If you recently installed python and its not setting latest path you may need to use following method to install python correctly in unix systems. Most of the users intend to create symlinks replacing python 2 with python 3 and its not a proper way to switch the versions. For that you can use pyenv and change desired python version easily.

Read more “Python is not setting correct path in mac os” →
optimize React.js load time JavaScript

How to optimize React.js app load time using react…

  • August 1, 2021August 1, 2021
  • by Coder Kai

Often React.js applications could grow larger and could be taking more time to load the content. React team offered a very useful technique to lazily load the bundled content without bundling it all together with the main bundle. This will optimize the load time and show the content without taking much time to load the content fully.

Read more “How to optimize React.js app load time using react lazy” →
dismiss dropdowns when pressed on background with React.js JavaScript

How to use IntersectionObserver to detect the position in…

  • July 11, 2021July 29, 2021
  • by Coder Kai

When working with web we often need to animate or reveal html elements by detecting the scroll position. One such example would be to display a container for a state variable and scroll. The IntersectionObserver is a useful interface to achieve such functionality.

Read more “How to use IntersectionObserver to detect the position in React” →
dismiss dropdowns when pressed on background with React.js JavaScript

How to dismiss dropdowns when pressed on background with…

  • July 4, 2021July 11, 2021
  • by Coder Kai

React components offer many advantages to break the code and implement web features. But when it comes to some features it could bit difficult to make it work. One such problem would be to listen to document click events and making the changes to components like dismissing dropdowns when pressed on the background.

Read more “How to dismiss dropdowns when pressed on background with React.js” →
Javascript guide Strings JavaScript

03. Javascript Guide – Strings

  • July 3, 2021August 1, 2021
  • by Coder Kai

Every programming language has strings that represent a set of characters. Javascript strings have some properties which are unique to the language. This guide covers these properties and important facts when using strings.

Read more “03. Javascript Guide – Strings” →
How to fetch data with useEffect JavaScript

How to fetch data with useEffect

  • July 2, 2021July 2, 2021
  • by Coder Kai

React hooks have been very promising solution for most of the coding issues that React framework had in old days. But for novice developers, it could be hard to understand. Especially if you are moving from old react to new. One of the main problem is how to fetch data with useEffect in a proper way.

Read more “How to fetch data with useEffect” →
add styles to stripe elements JavaScript

How to add styles to stripe elements without using…

  • June 29, 2021June 29, 2021
  • by Coder Kai

Stripe is a great way to make payments for your web or mobile platforms. Being a full service payment platform, Stripe also gives you a variety of SDKs to implement your backend and frontend code with the best compliance options. In this tutorial you will learn how to add styles to stripe elements if you don’t want to use existing styles of the card input.

Read more “How to add styles to stripe elements without using CardElement” →
Typescript JavaScript

How to use Typescript with arrays

  • June 28, 2021July 11, 2021
  • by Coder Kai

Array is used to store a sequence of elements as references. When declaring typescript array, the type of the elements should be defined in its syntax.

Read more “How to use Typescript with arrays” →
how to optimize react-native map view JavaScript

How to optimize react-native map views

  • June 26, 2021June 27, 2021
  • by Coder Kai

React native always has been quite painful when it comes to performance compared to a native application. Today we will focus on increasing the performance and how to optimize react-native map view which has many pegs or markers.

Read more “How to optimize react-native map views” →
debounce with react hooks JavaScript

Avoid multiple clicks using debounce with react hooks

  • February 16, 2021June 20, 2021
  • by Coder Kai

Why debounce with react hooks? We all come across that one button users keep on pressing until the data is loaded. Without guarding your code with every sort of if conditions, you can guard this by debouncing. For multiple tap scenarios, you can either propagate the event at the first tap/click or the last one.

Read more “Avoid multiple clicks using debounce with react hooks” →
Numbers inJavascript JavaScript

02. Javascript Guide – Numbers

  • December 15, 2019July 3, 2021
  • by Coder Kai

Numbers in Javascript

The numbers in Javascript has many subtle things to understand it fully. In this section, we are going to discuss the following points.

  1. What are the numbers in Javascript and memory representation.
  2. Number wrapper.
  3. Arithmetics.
  4. Points to remember when coding.
Read more “02. Javascript Guide – Numbers” →
Introduction to Javascript JavaScript

01. Javascript Guide – Introduction to Javascript

  • December 11, 2019December 15, 2019
  • by Coder Kai

Introduction to Javascript and the language

In this introduction to Javascript, we are going to discuss the following points.

  1. Javascript, the language
  2. Early Javascript
  3. Characteristics
  4. Tools
Read more “01. Javascript Guide – Introduction to Javascript” →
Docker

Nginx Load Balancer with docker for nodejs services

  • November 3, 2019December 11, 2019
  • by Coder Kai

Nginx Load Balancer with docker has become a fine recipe for managing services in closed systems. Although services like Kubernetes provide container orchestration, sometimes architecturally it could be an overkill. In this example, I will be showing how to use docker services using Nginx load balancer.

Nginx Load Balancer with docker

Read more “Nginx Load Balancer with docker for nodejs services” →

JavaScript

Create React App Using npx

  • November 3, 2019November 11, 2019
  • by Coder Kai

Here we are discussing creating react app using npx create-react-app. npx comes with npm 5.2 and higher.

Prerequisite: You need to install Node >= 8.10 on your machine.

Creating an app using npx command

npx create-react-app my-app

create-react-app set up the main structure of the application.

Important: If you previously installed create-react-app using npm, uninstall before using npx. Because npx always refer the latest version of libraries.

Read more “Create React App Using npx” →

JavaScript

Difference Between npx and npm

  • November 2, 2019November 3, 2019
  • by Coder Kai
  • npm – Javascript package manager
  • npx – Execute npm package binaries ( a tool for executing node packages )

npx comes bundled with npm version 5.2+.

npm

If you want to run a package using npm, you must specify that package in your package.json file and install a package locally on a project:

npm install package-name

npx

npx is a npm package runner.

Read more “Difference Between npx and npm” →

JavaScript

Simple Tab View Using react-tabs

  • October 28, 2019November 3, 2019
  • by Coder Kai

This article will guide you on how to create a simple tab component using the react-tabs library.

Install react-tabs using

yarn add react-tabs    why yarn ?

Basic Example 1

Read more “Simple Tab View Using react-tabs” →

Use Dynamic Segments Routing in Ember 2.0 JavaScript

The Common Errors that beginner React Developers Make

  • October 24, 2019July 4, 2021
  • by Coder Kai

1. React Must Be in Scope

Let’s assume we are creating “helloWorld.jsx” like below, you can see there is a compilation error display as “’React’ must be in scope when using JSX react/react-in-jsx-scope.”

const element = <h1>Hello World!</h1>
export default element;


This happens due to “React” import necessary in JSX file.The React library must also always be in scope from JSX code. To overcome this error “import React from “react”;” must be added into the file as follows.

Read more “The Common Errors that beginner React Developers Make” →

FCM Push Notification with React Native FCM

How to setup FCM Push Notification with React Native…

  • March 11, 2019March 11, 2019
  • by Coder Kai

If you are new to firebase and FCM this article will be useful to setup FCM Push Notification with React Native application. We will be using react-native-firebase(doc: https://rnfirebase.io/docs/v5.x.x/getting-started) module to retrieve token for the push notifications.

Prerequisites

First, create the Firebase account and download the google-services.json file from the console.

  1. Access your firebase account and go to the project settings from the top gear icon.
    Read more “How to setup FCM Push Notification with React Native App” →
Frequent errors with Apollo Client Apollo Client

Query definition in GraphQL and frequent errors with Apollo…

  • February 18, 2019March 11, 2019
  • by Coder Kai

Query definition in GraphQL is will be something you know now but not mastered. If you were going through the pages to troubleshoot frequent errors with Apollo Client which makes no sense, this post might help. First, the reason to create this post is,

  1. Most of the error logs are not descriptive and makes no clue on where the real error is.
  2. There can be so many different mistakes in coding the queries and difficulty in keeping on track of it.

And most importantly if I get into a trouble again, I can refer this 😉 Read more “Query definition in GraphQL and frequent errors with Apollo Client” →

Posts navigation

1 2

Categories

  • android 3
  • Apollo Client 1
  • AWS 7
    • AppSync 5
    • EC2 1
    • EKS 1
    • Route53 1
  • AWS Amplify 1
  • Docker 1
  • Embedded 1
  • EmberJS 1
  • FCM 1
  • Godaddy 1
  • GraphQL 3
  • ios 1
  • Jasper 1
  • Java 10
    • Java 11 1
    • Java 14 1
  • JavaEE 2
  • JavaScript 32
    • Express.js 4
    • Javascript Guide 3
    • Node.js 1
    • react-native 4
    • React.js 15
    • Typescript 1
  • Kubernetes 1
  • machine learning 1
  • Maven 2
  • OCaml 3
  • react-native 4
  • ReactJS 3
  • sass 1
  • Server 6
  • spark 1
  • Ubuntu 4
  • Uncategorized 1
  • webpack 2

Recent Comments

  • Johnny on SSL Websocket proxy with Nginx for Graphql Subscriptions
  • please read this for me on Why did Facebook pick OCaml?
  • Ashlep on How to host GoDaddy domain with AWS EC2

Meta

  • Log in
  • Entries feed
  • Comments feed
  • WordPress.org

Archives

  • May 2022 1
  • December 2021 1
  • August 2021 1
  • July 2021 6
  • June 2021 3
  • February 2021 1
  • July 2020 1
  • December 2019 5
  • November 2019 6
  • October 2019 3
  • August 2019 1
  • March 2019 1
  • February 2019 1
  • January 2019 2
  • December 2018 1
  • September 2018 2
  • August 2018 1
  • June 2018 1
  • February 2018 1
  • November 2017 2
  • October 2017 5
  • September 2017 1
  • June 2017 1
  • May 2017 10
Sandny Blog space
Theme by Colorlib Powered by WordPress