Skip to content

Instantly share code, notes, and snippets.

View fabrizzioRP's full-sized avatar
:octocat:
Hello :)

Fabrizzio Rosales fabrizzioRP

:octocat:
Hello :)
View GitHub Profile
@subfuzion
subfuzion / curl.md
Last active November 11, 2024 03:27
curl POST examples

Common Options

-#, --progress-bar Make curl display a simple progress bar instead of the more informational standard meter.

-b, --cookie <name=data> Supply cookie with request. If no =, then specifies the cookie file to use (see -c).

-c, --cookie-jar <file name> File to save response cookies to.

@Klerith
Klerith / parse-jwt.js
Created March 15, 2018 15:07
Parse - JWT - Obtener Payload y fecha de creación y expiración
function parseJwt (token) {
var base64Url = token.split('.')[1];
var base64 = base64Url.replace('-', '+').replace('_', '/');
return JSON.parse(window.atob(base64));
};
@Klerith
Klerith / index.ts
Last active August 23, 2024 21:46
Vuex + TypeScript - Store Structure Strongly Typed
import { createStore } from 'vuex';
// My custom modules
import exampleModule from './module-template';
import { ExampleStateInterface } from './module-template/state';
export interface StateInterface {
// Define your own store structure, using submodules if needed
// example: ExampleStateInterface;
@fabrizzioRP
fabrizzioRP / rectangle.dart
Last active December 23, 2021 23:28
Dart: Rectangle Container
final Widget rectangle = Container(
width : 150,
height : 70,
color : Colors.red,
child : Center(
child : Text('Rectangle'),
),
);
@fabrizzioRP
fabrizzioRP / fadein_navigate.dart
Created February 2, 2022 21:59
Function Navigate FadeIn
Route navigateScreenFadeIn( BuildContext context , Widget screen ) =>
PageRouteBuilder(
pageBuilder : ( _ , __ , ___) => screen,
transitionDuration : const Duration(milliseconds: 300),
transitionBuilder : ( context , animation , _, child) =>
FadeTransition(
opacity : Tween<double>(begin : 0.0 , end : 1.0).animate( CurvedAnimation( parent : animation , curve : Curves.easeOut ) ),
child : child
),
);
@Klerith
Klerith / README.md
Last active August 26, 2024 02:18
Deprecated Method - Decorador

@Deprecated - Method Decorator

En la definición del método, se puede marcar como obsoleto (deprecated) con la justificación. Esto ayudará a que otros developers sepán que deben de utilizar ya la alternativa.

@Deprecated('Most use speak2 method instead')
 speak() {
      console.log(`${ this.name }, ${ this.name }!`)
 }