Skip to content

Instantly share code, notes, and snippets.

Avatar
🚀
// TODO: be life good

William Correa wilcorrea

🚀
// TODO: be life good
View GitHub Profile
View checker.sh
#!/bin/bash
# usage:
# checker "https://myapp.com"
counter=0
while true
do
counter=$((counter + 1))
status=$(curl -o /dev/null -s -w "%{http_code}\n" ${1})
View twitter.css
.css-1dbjc4n.r-13awgt0.r-18u37iz.r-1w6e6rj,
[data-testid="unlike"] .css-901oao.css-16my406.r-1qd0xha.r-ad9z0x.r-bcqeeo.r-qvutc0,
[data-testid="like"] .css-901oao.css-16my406.r-1qd0xha.r-ad9z0x.r-bcqeeo.r-qvutc0,
.css-4rbku5.css-18t94o4.css-901oao.r-hkyrab.r-1loqt21.r-1qd0xha.r-a023e6.r-16dba41.r-ad9z0x.r-bcqeeo.r-qvutc0,
.css-901oao.css-16my406.r-4qtqp9.r-ip8ujx.r-sjv1od.r-zw8f10.r-bnwqim.r-h9hxbl > div {
display: none;
}
View index.php
<?php
# allow all methods
header('Access-Control-Allow-Methods: POST, GET, PUT, PATCH, DELETE, OPTIONS');
# allow some headers
header('Access-Control-Allow-Headers: Authorization, Bearer, Device, Origin, Accept, Content-Type');
# allow expose some headers
header('Access-Control-Expose-Headers: Authorization, Bearer, Device');
# get the request method
$method = $_SERVER['REQUEST_METHOD'] ?? null;
View TransactionHistory.vue
<template>
<QCard
bordered
style="min-height: calc(30vh + 40px)"
>
<QCardSection class="row">
<div class="col-sm-6 flex justify-sm-center justify-start items-center">
<div class="q-mb-md text-weight-medium">
{{ $lang('pages.dashboard.index.charts.transaction-history') }}
</div>
View ExampleSchema.ts
import Schema from '@devitools/Agnostic/Schema'
import Service from './InviteService'
import { domain } from '../settings'
import { Component, Context, SchemaTable } from '@devitools/Agnostic/Helper/interfaces'
import { positions, scopes, SCOPES } from '@devitools/Agnostic/enum'
import { unique } from '@devitools/Util/general'
import { RULES } from 'src/settings/schema'
import { replacement } from '@devitools/Util/string'
@wilcorrea
wilcorrea / Dockerfile
Last active Aug 21, 2020
Quasar with docker
View Dockerfile
# tevun/quasar
FROM node:alpine
RUN apk --update add openssh-client git
RUN npm install --global \
@vue/cli@4.5.4 && \
@vue/cli-init@4.5.4 \
@quasar/cli@1.1.0\
http-server@0.11.1
View register-service-worker.js
import { Loading, Notify } from 'quasar'
import { register } from 'register-service-worker'
import $lang from '@devitools/Lang'
// The ready(), registered(), cached(), updatefound() and updated()
// events passes a ServiceWorkerRegistration instance in their arguments.
// ServiceWorkerRegistration: https://developer.mozilla.org/en-US/docs/Web/API/ServiceWorkerRegistration
register(process.env.SERVICE_WORKER_FILE, {
// The registrationOptions object will be passed as the second argument
View docker-compose.yml
version: '3'
# Networks
networks:
# Internal network
internal:
driver: bridge
# Volumes
volumes:
View Category.php
<?php
declare(strict_types=1);
namespace Source\Domains\General;
use Devitools\Persistence\AbstractModel;
/**
* Class Category
View QPhoneInternational.vue
<template>
<QField
class="AppPhoneInternational"
v-bind="{ ...$attrs, ...$props }"
@clear="$emit('input', '')"
>
<div
ref="root"
class="AppPhoneInternational__root"
/>
You can’t perform that action at this time.