Skip to content

Instantly share code, notes, and snippets.

View lucasmotta's full-sized avatar

Lucas Motta lucasmotta

View GitHub Profile
@lucasmotta
lucasmotta / machine.js
Created April 22, 2020 10:48
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@lucasmotta
lucasmotta / machine.js
Last active April 16, 2020 15:53
Generated by XState Viz: https://xstate.js.org/viz
const videoMachine = Machine({
id: 'video',
initial: 'loading',
context: {
video: undefined,
duration: 0,
elapsed: 0,
},
@lucasmotta
lucasmotta / Podfile
Last active January 13, 2020 22:32
Using [email protected] with React Native >0.60
# This is needed for react-native-config
# See more: https://github.com/luggit/react-native-config/issues/187#issuecomment-468730417
post_install do |installer|
installer.pods_project.targets.each do |target|
if target.name == 'react-native-config'
phase = target.project.new(Xcodeproj::Project::Object::PBXShellScriptBuildPhase)
phase.shell_script = "cd ../../"\
" && RNC_ROOT=./node_modules/react-native-config/"\
" && export SYMROOT=$RNC_ROOT/ios/ReactNativeConfig"\
" && export BUILD_DIR=$RNC_ROOT/ios/ReactNativeConfig"\
@lucasmotta
lucasmotta / custom-vscode.css
Created May 9, 2018 14:28
custom-vscode-css
.monaco-tree, .part.sidebar {
font-family: "Operator Mono";
font-size: 12px;
}
@lucasmotta
lucasmotta / styles.less
Created October 12, 2016 13:24
Atom One Light Rainbow
/***********************************************
* GRADIENT THEME
**********************************************/
@gradient-start: #3E8CC4;
@gradient-end: #A07AB2;
@gradient-ui-background: #FFFFFF;
@gradient-ui-color: #000000;
@gradient-ui-opacity: 75%;
@gradient-padding: 8px;
@lucasmotta
lucasmotta / SassMeister-input-HTML.html
Created October 16, 2015 15:07
Generated by SassMeister.com.
<div class="group">
<h2>Shapes</h2>
<p>Modifiers: <span>underline</span>, <span>outline</span>, <span>pill</span></p>
<div class="btn">Button</div>
<div class="btn btn--underline">Underlined</div>
<div class="btn btn--outline">Outline</div>
<div class="btn btn--squared btn--outline">Squared</div>
<div class="btn btn--pill btn--outline">Pill Button</div>
</div>
@lucasmotta
lucasmotta / SassMeister-input-HTML.html
Last active October 16, 2015 13:15
Generated by SassMeister.com.
<div class="group">
<h2>Shapes</h2>
<p>Modifiers: <span>underline</span>, <span>outline</span>, <span>pill</span></p>
<div class="btn">Button</div>
<div class="btn btn--underline">Underlined</div>
<div class="btn btn--outline">Outline</div>
<div class="btn btn--pill btn--outline">Pill Button</div>
</div>
@lucasmotta
lucasmotta / react-router-issue.sh
Created September 3, 2015 12:18
Issue when running the react-webpack-node project
$ git:(upstream ⚡ master) 10A npm run dev
> [email protected] dev /Users/*******/Projects/personal/react-designer-news
> NODE_ENV=development node server/index.js
Environment: development
/Users/*******/Projects/personal/react-designer-news/public/assets/app.server.js:69
var _reactRouterLibLocation = __webpack_require__(!(function webpackMissingModule() { var e = new Error("Cannot find module \"react-router/lib/Location\""); e.code = 'MODULE_NOT_FOUND'; throw e; }()));
^
@lucasmotta
lucasmotta / is-port-being-used
Created July 20, 2015 11:15
Check if a specific port is being used on Mac OX
sudo lsof -i :8000 # checks port 8000
@lucasmotta
lucasmotta / delete-empty-folders.sh
Created June 15, 2015 08:42
Delete all empty folders recursively
find . -type d -empty -delete