Hi there 👋

Welcome to GeekyHub.

  • GeekyHub is a place to share my thoughts, opinion and Experiences on Technologies.
Photo by RealToughCandy.com: https://www.pexels.com/photo/man-love-people-woman-11035380/

Stop using serverless-webpack for AWS Lambda

I see that nodejs lambda projects are built using serverless and often include serverless-webpack. It is used to implement babel and get the latest javascript syntaxes, especially module and top-level awaits. But as per this blog post, the AWS lambda environment already supports these features, so we should no longer need to use serverless-webpack. There are some cons that I face while using webpack in serverless. Code is transpiled (and optionally minified), making it challenging to debug from logs, as line numbers and function names may not be the same per your development environment....

October 6, 2022 · 1 min · Vikas Kumar
Multiple stores

Journey of building a game using the Flutter

For the last few weeks, I have been working on a React Native project for work. So this was my first experience writing “real” mobile apps. Before that, I only wrapped PWA’s as APK and called myself a mobile developer 😎. React-Native came naturally to me after climbing some learning curves as a React Developer. So, now I wanted to check out the buzz around Flutter. So last weekend was a fine sunny day which is quite pleasing in the late winter season....

February 19, 2022 · 2 min · Vikas Kumar
Animation in React Native

Animate SVG in React Native

Here, by animating SVG, I mean to change the property of SVG elements dynamically, which will look live-like. In react native, we can generate/render an SVG using the react-native-svg library. A complex SVG comprises many more minor elements that could be animated individually. But here, for example, we will take only one piece, a circle. The following code will draw a circle with a radius of 50 units. <Svg width={200} height={200}> <Circle cx="55" cy="55" r="50" stroke="black" strokeWidth={5} /> </Svg> Suppose we want to animate it to become large and small....

February 5, 2022 · 2 min · Vikas Kumar
Multiple stores

Handling multiple stores in a React-Redux application

In a react-redux application, it is a good practice to have only one redux store. But if for some weird/“special” reason if you have to have more than one store, you will face some problems. The most common problem is that if we wrap a component with a provider and then wrap a child component with another provider, it’s not easy to subscribe to the store of top-level provider. const Component1 = () => { return ( <Provider store={store1}> <Provider store={store2}> <Component2 /> </Provider> </Provider> ); }; It’s so confusing that within a few iterations of development, you’ll find yourself using providers on each component, and not being able to read values from both the stores in a single component will frustrate you....

October 12, 2021 · 2 min · Vikas Kumar
useEffect vs direct Function Call

Difference between 'useEffect' and calling function directly inside a component.

In React, the useEffect hook is pretty straightforward. But its simplicity sometimes makes me forget its actual function. I remembered useEffect simply as something which takes a callback and a dependency array as arguments, and it will execute the callback whenever the dependency array is changed. And in case of no dependency array, it will run the callback each time the component renders. But then what will be the difference between the following two cases....

May 9, 2021 · 3 min · Vikas Kumar