I hereby claim:
- I am nandomoreirame on github.
- I am onandomoreira (https://keybase.io/onandomoreira) on keybase.
- I have a public key ASCWboqGKY1Tl79c0VTsmn4LKZNn678UOOnOH9GJzUFaFAo
To claim this, I am signing this object:
let _lsTotal = 0; | |
let _xLen; | |
let _x; | |
for (_x in localStorage) { | |
if (!localStorage.hasOwnProperty(_x)) { | |
continue; | |
} | |
_xLen = ((localStorage[_x].length + _x.length) * 2); | |
_lsTotal += _xLen; |
const timeout = ms => new Promise(resolve => setTimeout(resolve, ms)); | |
const sleep = async (fn, ...args) => { | |
await timeout(3000); | |
return fn(...args); | |
}; |
export default function ({ $axios }, { redirect }) { | |
$axios.defaults.headers['Content-Type'] = 'application/json'; | |
$axios.onRequest((config) => { | |
const apiToken = process.env.API_USER_TOKEN || ''; | |
config.headers.Authorization = apiToken ? `JWT ${apiToken}` : ''; | |
console.log(`${config.baseURL}${config.url}`, 'Request'); | |
return config; |
import { replaceUrl } from './utils'; | |
export default { | |
computed: { | |
partnerImage() { | |
return replaceUrl(this.item.partner.imageUrl); | |
}, | |
}, | |
}; |
const state = { | |
loading: false, | |
geolocation: {}, | |
}; | |
const mutations = { | |
TOGGLE_LOADING(state, payload) { | |
state.loading = !!payload; | |
}, | |
CHANGE_GEOLOCATION(state, payload) { |
const form = { | |
name: '', | |
email: '', | |
phone: '', | |
message: '' | |
} | |
export default { | |
data: () => ({ | |
form |
I hereby claim:
To claim this, I am signing this object:
<?php | |
function get_page_id_by_slug($page_slug) { | |
$page = get_page_by_path($page_slug); | |
if ($page) { | |
return $page->ID; | |
} | |
return null; |
import axios from 'axios' | |
import NProgress from 'nprogress' | |
import config, { isProduction } from '@/config' | |
/** | |
* Axios methods | |
* Doc: https://kapeli.com/cheat_sheets/Axios.docset/Contents/Resources/Documents/index | |
* | |
* http | |
* .get(url, { params }) |
# https://editorconfig.org | |
root = true | |
[*] | |
indent_style = space | |
indent_size = 2 | |
end_of_line = lf | |
charset = utf-8 | |
trim_trailing_whitespace = true | |
insert_final_newline = true |