Skip to content

Instantly share code, notes, and snippets.

View afucher's full-sized avatar

Arthur Fücher afucher

View GitHub Profile
/*
This example requires some changes to your config:
```
// tailwind.config.js
module.exports = {
// ...
plugins: [
// ...
require('@tailwindcss/forms'),
@afucher
afucher / main.dart
Created July 27, 2022 13:13
divine-spray-6506
class Foo {
final String? p1;
const Foo({
this.p1 = "default"
});
}

Extension

Create a new operation: allow-list.

That operation will change the number of rules that should be applied. When an account is allow-listed, authorizer should validate only two rules:

  1. The transaction amount should not be above limit
  2. No transaction should be approved when the card is blocked

The account is not allow-listed by default, and once it is allow-listed it can be disabled with a new allow-list operation.

@afucher
afucher / consoleDir.cs
Created January 19, 2021 23:05
[dotnet] Imprime propriedades e valores de um objeto
foreach(PropertyDescriptor descriptor in TypeDescriptor.GetProperties(obj))
{
string name=descriptor.Name;
object value=descriptor.GetValue(obj);
Console.WriteLine("{0}={1}",name,value);
}
@afucher
afucher / git-anonymize
Created October 13, 2019 23:07 — forked from pozorvlak/git-anonymize
Anonymise Git history
#!/bin/sh
# Suppose you want to do blind reviewing of code (eg for job interview
# purposes). Unfortunately, the candidates' names and email addresses are
# stored on every commit! You probably want to assess each candidate's version
# control practices, so just `rm -rf .git` throws away too much information.
# Here's what you can do instead.
# Rewrite all commits to hide the author's name and email
for branch in `ls .git/refs/heads`; do
import { Link } from "gatsby"
import PropTypes from "prop-types"
import React, { useState } from "react"
const Header = ({ siteTitle }) => {
useState(false);
return (
<header
style={{
background: `rebeccapurple`,
'use strict';
const PDFDocument = require('pdfkit');
const fs = require('fs');
const printHeader = doc => {
const opt = {continued: true};
doc.text("Name", opt);
doc.x = 200;
doc.text("Start date", opt);
doc.x = 250;
@afucher
afucher / example.spec.js
Created November 2, 2018 01:11
vue cli service error
import { expect } from 'chai'
import VueResource from 'vue-resource'
describe('HelloWorld.vue', () => {
it('renders props.msg when passed', () => {
expect(true).to.be.true
})
})
package main
import (
"fmt"
)
func main() {
tstSlice2()
}
'use strict';
const CreateGroupList = require('../utils/GroupsListPDF');
const Group = require('../models').Group;
const Client = require('../models').Client;
const Course = require('../models').Course;
const ClientGroup = require('../models').ClientGroup;
const Boom = require('boom');
const moment = require('moment');
const fields = ['id','start_date','end_date','start_hour','end_hour','course_id','classes','teacher_id','classes'];
const teacher = {model: Client, as: 'Teacher', attributes: ['name']}