Skip to content

Instantly share code, notes, and snippets.

View matheusnascgomes's full-sized avatar

Matheus Gomes matheusnascgomes

View GitHub Profile
@matheusnascgomes
matheusnascgomes / vscodeconfig.json
Created August 29, 2018 13:16
Basic VSCode settings for an automatized formatting with Prettier Plugin
{
"gitlens.advanced.messages": {
"suppressShowKeyBindingsNotice": true
},
"diffEditor.ignoreTrimWhitespace": false,
"window.zoomLevel": 0,
"git.path": "user/bin/git",
"eslint.autoFixOnSave": true,
"eslint.alwaysShowStatus": true,
"editor.formatOnSave": true,
@matheusnascgomes
matheusnascgomes / AndroidManifest.xml
Last active January 7, 2019 12:03
react-native-share failed setup
<provider
android:name="android.support.v4.content.FileProvider"
android:authorities="com.appfidelizaclientes.provider"
android:grantUriPermissions="true"
android:exported="false">
<meta-data
android:name="android.support.FILE_PROVIDER_PATHS"
android:resource="@xml/filepaths" />
</provider>
@matheusnascgomes
matheusnascgomes / setup.js
Created January 9, 2019 02:09
Setup da Biblioteca react-native-share
console.log('');
@matheusnascgomes
matheusnascgomes / tip.md
Last active June 7, 2019 01:42
When you build the project's apk and the result is an older apk version, update the generated output by doing this

When you build the project's apk and the result is an older apk version, update the generated output by doing this

Run the following command and then try build the app again

react-native bundle --platform android --dev false --entry-file index.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res

@matheusnascgomes
matheusnascgomes / rideDetailsRedux.js
Created February 9, 2019 18:42
Estruta Redux + Redux Saga
export const Types = {
GET_REQUEST: 'ride/GET_REQUEST',
GET_SUCCESS: 'ride/GET_SUCCESS',
};
const INITIAL_STATE = {
data: null,
};
export default function rideDetails(state = INITIAL_STATE, action) {
var marcados = 0;
var verifyCheckeds = function($checks) {
if( marcados >= 2 ) {
loop($checks, function($element) {
$element.disabled = $element.checked ? '' : 'disabled';
});
} else {
loop($checks, function($element) {
$element.disabled = '';
@matheusnascgomes
matheusnascgomes / gitconfig.md
Last active May 23, 2023 12:00
Usefull git alias
[alias]
st = status
        co = commit
        logone = log --oneline
        lg = log --pretty=format:'%Cred%h%Creset %C(bold)%cr%Creset %Cgreen<%an>%Creset %s' --max-count=30
        ck = checkout
        copy = checkout -b
 br = branch
@matheusnascgomes
matheusnascgomes / .eslintrc.js
Last active November 17, 2021 22:19 — forked from diego3g/.eslintrc.js
A basic setup on typescript linter in a React Project
module.exports = {
env: {
browser: true,
es6: true,
jest: true,
},
extends: [
'react-app',
'airbnb',
'plugin:@typescript-eslint/recommended',
@matheusnascgomes
matheusnascgomes / tests.md
Last active May 29, 2019 01:23
React tests workstation using Create React App