Skip to content

Instantly share code, notes, and snippets.

@nurbek-ab
nurbek-ab / git-ssh-auth-win-setup.md
Created January 5, 2019 06:08 — forked from bsara/git-ssh-auth-win-setup.md
Setup SSH Authentication for Git Bash on Windows

Setup SSH Authentication for Git Bash on Windows

Prepararation

  1. Create a folder at the root of your user home folder (Example: C:/Users/uname/) called .ssh.
  2. Create the following files if they do not already exist (paths begin from the root of your user home folder):
  • .ssh/config
@nurbek-ab
nurbek-ab / connect.js
Created November 29, 2019 23:51 — forked from gaearon/connect.js
connect.js explained
// connect() is a function that injects Redux-related props into your component.
// You can inject data and callbacks that change that data by dispatching actions.
function connect(mapStateToProps, mapDispatchToProps) {
// It lets us inject component as the last step so people can use it as a decorator.
// Generally you don't need to worry about it.
return function (WrappedComponent) {
// It returns a component
return class extends React.Component {
render() {
return (
@nurbek-ab
nurbek-ab / removeSearchParam.js
Created October 4, 2020 14:55
Remove URL search parameter
const removeSearchParam = param => {
const url = new URL(window.location.href)
url.searchParams.delete(param)
window.history.replaceState(null, null, url)
}