Skip to content

Instantly share code, notes, and snippets.

View andersonferrari's full-sized avatar
🚀

Anderson Luiz Ferrari andersonferrari

🚀
View GitHub Profile
@scottmcarthur
scottmcarthur / program.cs
Created February 9, 2014 12:23
Transparent encoding/decoding Id properties in ServiceStack v4
using System;
using ServiceStack;
using System.Text;
using ServiceStack.Web;
namespace ComplexIdTest
{
class MainClass
{
public static void Main()
@gaearon
gaearon / connect.js
Last active April 11, 2024 06:46
connect.js explained
// connect() is a function that injects Redux-related props into your component.
// You can inject data and callbacks that change that data by dispatching actions.
function connect(mapStateToProps, mapDispatchToProps) {
// It lets us inject component as the last step so people can use it as a decorator.
// Generally you don't need to worry about it.
return function (WrappedComponent) {
// It returns a component
return class extends React.Component {
render() {
return (