Skip to content

Instantly share code, notes, and snippets.

View JimmyMultani's full-sized avatar
🏠
Working from home

Jimmy Multani JimmyMultani

🏠
Working from home
View GitHub Profile
@Grsmto
Grsmto / react-table.d.ts
Created March 6, 2019 12:59
React Table v7 TS typings definition
// Type definitions for react-table 7
// Project: https://github.com/tannerlinsley/react-table#readme
// Definitions by: Grsmto <https://github.com/grsmto>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 3.0
declare module 'react-table' {
export type Cell = {
render: (type: string) => any;
getCellProps: () => any;
column: Column;
@qoomon
qoomon / conventional_commit_messages.md
Last active April 14, 2024 20:54
Conventional Commit Messages

Conventional Commit Messages

See how a minor change to your commit message style can make a difference.

Tip

Have a look at git-conventional-commits , a CLI util to ensure these conventions and generate verion and changelogs

Commit Message Formats

Default

@prescottprue
prescottprue / snapshotResolver.js
Created November 26, 2018 21:54
Jest snapshot resolver for snapshots at top level of repo when tests are in component folders.
const path = require('path')
const rootDir = path.resolve(__dirname, '..')
module.exports = {
/** resolves from test to snapshot path */
resolveSnapshotPath: (testPath, snapshotExtension) => {
return testPath.replace('src/', '__snapshots__/') + snapshotExtension
},
@newswim
newswim / antd_sc_example.js
Created August 4, 2017 22:42
Wrapping Ant Design components with Styled Components
import { Link } from 'react-router-dom'
import { Badge, Col, Menu } from 'antd'
const StyledBadge = styled(Badge)`
.ant-badge-count {
background-color: #7ECBBF;
color: white;
box-shadow: 0 0 0 1px #d9d9d9 inset;
}
`
@TSMMark
TSMMark / delete_local_branches.sh
Last active February 20, 2023 05:41
Delete local branches that don't exist on remote/origin !USE AT YOUR OWN RISK!
git fetch --all -p; git branch -vv | grep ": gone]" | awk '{ print $1 }' | xargs -r -n 1 git branch -D
@coolaj86
coolaj86 / how-to-publish-to-npm.md
Last active April 2, 2024 20:18
How to publish packages to NPM

Getting Started with NPM (as a developer)

As easy as 1, 2, 3!

Updated:

  • Aug, 08, 2022 update config docs for npm 8+
  • Jul 27, 2021 add private scopes
  • Jul 22, 2021 add dist tags
  • Jun 20, 2021 update for --access=public
  • Sep 07, 2020 update docs for npm version