Skip to content

Instantly share code, notes, and snippets.

View ShreyaPrasad1209's full-sized avatar
🌻
Doing more than just existing!

Shreya Prasad ShreyaPrasad1209

🌻
Doing more than just existing!
View GitHub Profile
import type { ReactNode } from "react";
import type { Props as ReactIntlFormattedMessageProps } from "react-intl/src/components/message";
import { FormattedMessage as ReactIntlFormattedMessage } from "react-intl";
import enMessages from "./en.json";
// Our new union type of all available message IDs.
type IntlMessageKeys = keyof typeof enMessages;
// Extend the original FormattedMessage props.
type FormattedMessageProps = ReactIntlFormattedMessageProps<
@thealphadollar
thealphadollar / AutoConnectLinkedIn.js
Last active April 30, 2024 19:20
JS script to send connection requests to your LinkedIn search results with customisation options, accept all received connection requests, and withdraw pending sent connection requests.
// If the script does not work, you may need to allow same site scripting https://stackoverflow.com/a/50902950
Linkedin = {
config: {
scrollDelay: 3000,
actionDelay: 5000,
nextPageDelay: 5000,
// set to -1 for no limit
maxRequests: -1,
totalRequestsSent: 0,
@jwo
jwo / index.js
Created October 26, 2017 20:24
Simple way to sign in with github for oAuth in Node/Express
const express = require("express")
const app = express()
var passport = require("passport")
var session = require("express-session")
var GitHubStrategy = require("passport-github2").Strategy
const GITHUB_CLIENT_ID = "your-client-id-here" // or get from process.env.GITHUB_CLIENT_ID
const GITHUB_CLIENT_SECRET = "your-client-secret-here" // or get from process.env.GITHUB_CLIENT_SECRET
const GITHUB_CALLBACK_URL = "http://localhost:5000/auth/github/callback" // or get from process.env.GITHUB_CALLBACK_URL
@eveningkid
eveningkid / how-to-use-react-intl.md
Created July 28, 2017 16:33
How To Use React-Intl: internationalize your React app

How To Use React-Intl: internationalize your React app

This short tutorial assumes you know about ES6 syntax.

Get started

yarn add react-intl or npm i --save react-intl.

Create a messages file

This file should contain every message for your app.
It has an object of (locale, messages) couples:

@maksii
maksii / linkedin auto-inviter
Last active December 19, 2020 16:54
Script to automatically add connections from "People You May Know" page
var inviter = {} || inviter;
inviter.userList = [];
inviter.className = 'button-secondary-small';
inviter.refresh = function () {
window.scrollTo(0, document.body.scrollHeight);
window.scrollTo(document.body.scrollHeight, 0);
window.scrollTo(0, document.body.scrollHeight);
};
@mycodeschool
mycodeschool / BalancedParentheses.cpp
Created October 29, 2013 00:49
C++ Program to check for balanced parentheses in an expression using stack.
/*
C++ Program to check for balanced parentheses in an expression using stack.
Given an expression as string comprising of opening and closing characters
of parentheses - (), curly braces - {} and square brackets - [], we need to
check whether symbols are balanced or not.
*/
#include<iostream>
#include<stack>
#include<string>
using namespace std;
@charlierm
charlierm / linked_list.cpp
Last active April 25, 2024 09:11
Linked list written in c++
#include <iostream>
#include <cstdlib>
class Node
{
public:
Node* next;
int data;
};