Skip to content

Instantly share code, notes, and snippets.

Avatar

Lucas Motta lucasmotta

View GitHub Profile
View machine.js
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
View machine.js
const videoMachine = Machine({
id: 'video',
initial: 'loading',
context: {
video: undefined,
duration: 0,
elapsed: 0,
},
@lucasmotta
lucasmotta / Podfile
Last active Jan 13, 2020
Using react-native-config@0.11.7 with React Native >0.60
View Podfile
# 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"\
View custom-vscode.css
.monaco-tree, .part.sidebar {
font-family: "Operator Mono";
font-size: 12px;
}
@lucasmotta
lucasmotta / styles.less
Created Oct 12, 2016
Atom One Light Rainbow
View styles.less
/***********************************************
* 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 Oct 16, 2015
Generated by SassMeister.com.
View SassMeister-input-HTML.html
<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 Oct 16, 2015
Generated by SassMeister.com.
View SassMeister-input-HTML.html
<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 Sep 3, 2015
Issue when running the react-webpack-node project
View react-router-issue.sh
$ git:(upstream ⚡ master) 10A npm run dev
> react-designer-news@1.0.0 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 Jul 20, 2015
Check if a specific port is being used on Mac OX
View is-port-being-used
sudo lsof -i :8000 # checks port 8000
@lucasmotta
lucasmotta / delete-empty-folders.sh
Created Jun 15, 2015
Delete all empty folders recursively
View delete-empty-folders.sh
find . -type d -empty -delete
You can’t perform that action at this time.