Skip to content

Instantly share code, notes, and snippets.

View MaizerGomes's full-sized avatar
🎯
Focusing

Maizer Aly de Oliveira Gomes MaizerGomes

🎯
Focusing
View GitHub Profile
@MaizerGomes
MaizerGomes / OrdersComponent.tsx
Created July 25, 2023 09:46 — forked from mortezashojaei/OrdersComponent.tsx
Using laravel-echo in reactjs
import React, { FC } from 'react';
import { useSocket } from '@myapp/hooks';
import {Order} from '@myapp/models';
export const OrdersComponent: FC = () => {
const [orders,setOrders] = useState<Order[]>();
function addNewOrder(neworder:Order) {
@MaizerGomes
MaizerGomes / share-urls.md
Created July 6, 2023 08:22 — forked from apisandipas/share-urls.md
Share url's for Facebook, Twitter, Pinterest and Linkedin with just get variables

Creating share buttons with just URL's

Twitter

http://twitter.com/share?text=<TITLE>&url=<URL>

E.g. http://twitter.com/share?text=This+is+google+a+search+engine&url=https%3A%2F%2Fwww.google.com

Facebook

http://www.facebook.com/sharer.php?u=&amp;p[title]=

@MaizerGomes
MaizerGomes / gmail_attachment_downloader.py
Last active January 15, 2021 16:07 — forked from x011/gmail_attachment_downloader.py
Gmail Attachment Downloader 2020
from imap_tools import MailBox, AND # pip3 install imap_tools
import traceback
from datetime import datetime
from sys import exit
import os
host = "imap.gmail.com"
username = ""
password = ''
download_folder = "/home/maizerg/Downloads/sigeup"
@MaizerGomes
MaizerGomes / Vee Validate - Validating Child components
Created November 13, 2020 12:28 — forked from Danilo-Araujo-Silva/Vee Validate - Validating Child components
A strategy to validate child components with Vue and Vee Validate.
// Somewhere in the initialization:
import VeeValidate from "vee-validate";
Vue.use(VeeValidate);
// Then, in the parent component:
export default {
provide () {
return { parentValidator: this.$validator }
},
@MaizerGomes
MaizerGomes / js-atm-lab-solution.html
Created May 23, 2019 13:50 — forked from jongrover/js-atm-lab-solution.html
JavaScript ATM (part 1) Lab Solution
<script>
var balance = 100.0; //set initial balance.
function get_balance() {
alert('Your current balance is: '+balance);
atm();
}
function make_deposit() {
var deposit = parseFloat(prompt('How much would you like to deposit?'));
@MaizerGomes
MaizerGomes / nginx.conf
Created September 21, 2017 08:29 — forked from plentz/nginx.conf
Best nginx configuration for improved security(and performance). Complete blog post here http://tautt.com/best-nginx-configuration-for-security/
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048
@MaizerGomes
MaizerGomes / perfectelementary.bash
Created February 19, 2017 23:15
HowTo Install the perfect Elementary-OS
#Download Elementary OS from here:
#http://sourceforge.net/projects/elementaryos/files/stable/
#First you update your system
sudo apt-get update && sudo apt-get dist-upgrade
#Install Google Chrome
wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
sudo sh -c 'echo "deb http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list'
@MaizerGomes
MaizerGomes / perfectelementary.bash
Created February 19, 2017 23:15
HowTo Install the perfect Elementary-OS
#Download Elementary OS from here:
#http://sourceforge.net/projects/elementaryos/files/stable/
#First you update your system
sudo apt-get update && sudo apt-get dist-upgrade
#Install Google Chrome
wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
sudo sh -c 'echo "deb http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list'
/**
* Created by Maizer on 26/09/2016.
*/
var eKutivaFn = {
helpers: {
count: function count(mixedVar, mode) {
// discuss at: http://locutus.io/php/count/
// original by: Kevin van Zonneveld (http://kvz.io)
// input by: Waldo Malqui Silva (http://waldo.malqui.info)
// input by: merabi