Skip to content

Instantly share code, notes, and snippets.

View suvel-the-dev's full-sized avatar
🎯
Focusing

suvel-the-dev

🎯
Focusing
View GitHub Profile
@suvel-the-dev
suvel-the-dev / setup_nodeENV_in_WSL.md
Created May 24, 2022 12:48
instruction to install node and npm successfully in WSL

Setup a node.js env in WSL

I was trying to install nodejs in WSL for Emulating a server enviourment for creating and test a code before deploying into server. I was able to install the node successfully, but had issue with using npm. After a lot searching I was able to fix the issue by using nvm, here I am sharing the step for the same hope it helps.

I had also uninstalled the nodejs before proceding the nvm installation, here are commands for to perform the same:

  1. removing nodejs

    sudo get-apt remove nodejs
    
@suvel-the-dev
suvel-the-dev / subrouteSnippt.js
Last active August 9, 2021 10:47
subroute decalration snippt
/**
* @subroute<number>
* <param_type> param
* @param {<type>} <name>
*/
router.<method>("<subroute>", async function (req, res, next) {
const <param_variable> = req.<param_type>;
const action = <paramVariable>.action;
@suvel-the-dev
suvel-the-dev / .babelrc
Last active August 6, 2021 18:16
r3f with react-spring and webpack config
{
"presets": [
[
"@babel/preset-env",
{
"modules": false
}
],
"@babel/preset-react"
],