Skip to content

Instantly share code, notes, and snippets.

View wootsbot's full-sized avatar
:octocat:
Doing this 'n' that.

jlca wootsbot

:octocat:
Doing this 'n' that.
View GitHub Profile
@JamieMason
JamieMason / html-languages.txt
Created September 19, 2012 08:50
HTML lang attribute / ISO language code reference / Culture names
CULTURE SPEC.CULTURE ENGLISH NAME
--------------------------------------------------------------
Invariant Language (Invariant Country)
af af-ZA Afrikaans
af-ZA af-ZA Afrikaans (South Africa)
ar ar-SA Arabic
ar-AE ar-AE Arabic (U.A.E.)
ar-BH ar-BH Arabic (Bahrain)
ar-DZ ar-DZ Arabic (Algeria)
ar-EG ar-EG Arabic (Egypt)
@dearaujoj
dearaujoj / remove_git_tag
Created October 22, 2013 10:02
git remove tag locally and remote
git tag -d TagName && git push origin :refs/tags/TagName
@wesbos
wesbos / tab-trigger.js
Created November 16, 2015 19:33
How to properly get a TAB trigger working with Emmet inside of JSX
{
"keys": ["tab"],
"command": "expand_abbreviation_by_tab",
// put comma-separated syntax selectors for which
// you want to expandEmmet abbreviations into "operand" key
// instead of SCOPE_SELECTOR.
// Examples: source.js, text.html - source
"context": [
{
@gaearon
gaearon / index.js
Last active January 21, 2025 08:07
Breaking out of Redux paradigm to isolate apps
import React, { Component } from 'react'
import Subapp from './subapp/Root'
class BigApp extends Component {
render() {
return (
<div>
<Subapp />
<Subapp />
<Subapp />
@zebulonj
zebulonj / .npmrc
Last active March 20, 2023 04:33
Dockerfile with Private npm Module Dependencies
//registry.npmjs.org/:_authToken=${NPM_TOKEN}
save-exact=true
loglevel=error
@alexcalaca
alexcalaca / How to remove RVM from cloud9.md
Last active April 13, 2024 15:40
How to remove RVM from cloud9
@adhithiravi
adhithiravi / VideoComponent.js
Created August 16, 2018 19:34
VideoComponent.js
import React, {Component} from 'react'
import PropTypes from 'prop-types'
import { View, StyleSheet } from 'react-native'
import Video from 'react-native-video'
export default class VideoComponent extends React.Component {
renderVideo () {
return(
<Video
@gaearon
gaearon / uselayouteffect-ssr.md
Last active May 2, 2025 03:01
useLayoutEffect and server rendering

If you use server rendering, keep in mind that neither useLayoutEffect nor useEffect can run until the JavaScript is downloaded.

You might see a warning if you try to useLayoutEffect on the server. Here's two common ways to fix it.

Option 1: Convert to useEffect

If this effect isn't important for first render (i.e. if the UI still looks valid before it runs), then useEffect instead.

function MyComponent() {
@wootsbot
wootsbot / contribuye.rst
Created June 6, 2019 03:20
Publica tu artículo en codea.com.mx

Publica tu artículo en codea.com.mx

Clona el repositorio y prepara tu branch

$ git clone https://github.com/<mi-usuario-gitlab>/codea.git
$ cd codea/
@kmrk
kmrk / --copy-files
Last active January 16, 2020 23:58
babel --copy-files with --ignore
#!/usr/bin/env node
// babel's cli option --copy-files will override the --ignore setting
// so copy resources like this
require('fs-extra').copy(
process.argv.slice(-2).shift(),
process.argv.slice(-2).pop(),
{ filter: (src,dist)=>{ return (src.match(/\.js|\.jsx|stories|test/)===null)} },
err => { if (err) return console.error (err); console.log ('Copy success!');