Skip to content

Instantly share code, notes, and snippets.

Avatar

Fabien bonustrack

View GitHub Profile
@perfectmak
perfectmak / abi.json
Created Jun 1, 2022
Starknet Code to interact with Poster Contract on Chain
View abi.json
[
{
"data": [
{
"name": "address",
"type": "felt"
},
{
"name": "content_len",
"type": "felt"
View congress.sol
// SPDX-License-Identifier: GPL-3.0-or-later
pragma solidity >=0.7.0 <0.8.0;
contract CongressRegistry {
// The first key is the delegator and the second key a id.
// The value is the address of the delegate
mapping (address => address) public delegation;
mapping (address => uint256) public expiration;
mapping (address => bytes) public affiliation;
View dappnode-dao-snapshot-multichain-strategy.json
[
{
"name": "DAppNodeDAO staked in Unipool rewards contracts multichain",
"strategy": {
"name": "multichain",
"params": {
"strategies": [
{
"name": "unipool-univ2-lp",
"network": 1,
@djmaze
djmaze / OrbitTest.vue
Last active Dec 19, 2021
Using OrbitDB as a reactive store with VueJS
View OrbitTest.vue
<template>
<div>
<button @click="addItem('wut')">count is: {{ count }}</button>
<div
v-for="result in results"
:key="result.id"
@click="removeItem(result.id)"
>
{{ result.id }}
View oscript2.md

Changes in Oscript 2.0

Functions

$f = ($x) => {
	 $a = var['a'];
	 $x * $a
};

// one-line syntax for functions that have only one expression
@tonyofbyteball
tonyofbyteball / gist:ca071b74babdb368c0435fdff94f6858
Created Apr 20, 2020
Uniswap-like market maker with single-token contributions
View gist:ca071b74babdb368c0435fdff94f6858
{
init: `{
$asset = 'n9y3VomFeWFeZZ2PcSEcmyBb/bI7kzZduBJigNetnkY=';
$mm_asset = var['mm_asset'];
}`,
messages: {
cases: [
{ // define share asset
if: `{ trigger.data.define AND !$mm_asset }`,
messages: [
@BjornvdLaan
BjornvdLaan / BLSExample.sol
Last active Sep 29, 2022
Verification of BLS signatures and BGLS aggregate signatures in Ethereum
View BLSExample.sol
pragma solidity ^0.4.14;
/*
Example of how to verify BLS signatures and BGLS aggregate signatures in Ethereum.
Signatures are generated using https://github.com/Project-Arda/bgls
Code is based on https://github.com/jstoxrocky/zksnarks_example
*/
contract BLSExample {
View Home.vue
<template>
<Page class="page">
<ActionBar class="action-bar" title="Miyha">
<NavigationButton text="Menu" icon="res://ic_list_black_24dp" @tap="toggleDrawer" />
<StackLayout orientation="horizontal">
<Image src="res://icon" width="40" height="40" verticalAlignment="center" />
<Label text="iyha" fontSize="24" verticalAlignment="center" />
</StackLayout>
</ActionBar>
<SideDrawer>
@bonustrack
bonustrack / account.json
Last active Sep 25, 2016
Steem Script: An Open JSON Standard for Trusted Workflows
View account.json
{
"version": "0.0.1",
"dns": {"records":[["@","CNAME","steem.io"]]}},
"profile": {
"name": "Ned Scott",
"email": "ned@steem.io",
"birthday": "12/31/1999",
"gender": "male",
"about": "CEO and Co-founder at Steemit",
"first_name": "Ned",