Skip to content

Instantly share code, notes, and snippets.

View scastiel's full-sized avatar

Sebastien Castiel scastiel

View GitHub Profile
@scastiel
scastiel / pm-inbox-theme.css
Last active November 3, 2019 21:06
Inbox theme for ProtonMail
/**
* Hey :)
* The theme has moved to a dedicated repository: https://github.com/scastiel/pm-inbox-theme
*/
Verifying that "scastiel.id" is my Blockstack ID. https://onename.com/scastiel
// Installer fs-promise avec : npm install fs-promise
const http = require('http')
const fs = require('fs-promise')
function factorial (n) {
return n === 0 ? 1 : n * factorial(n - 1)
}
const server = http.createServer((req, res) => {
const data = {
persons: [
{ id: 0, name: "Sherlock Holmes", numbers: ["555-0101", "555-0199"] },
{ id: 1, name: "John Watson", numbers: ["555-0102", "555-0198"] }
],
groups: [
{ id: 0, name: "Londonians", personsIds: [0, 1] },
{ id: 1, name: "Doctors", personsIds: [1] }
]

Quiz


Question 1

Qu'affiche le programme suivant ?

function f() {
@scastiel
scastiel / wakeMeUp.sol
Created May 31, 2018 00:23
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.4.24+commit.e67f0147.js&optimize=false&gist=
pragma solidity ^0.4.0;
contract WakeMeUp {
event Print(string _name, uint _value);
event PrintString(string _name, bytes32 _value);
struct Alarm {
uint id;
address owner;
@scastiel
scastiel / queries.graphql
Last active April 21, 2019 16:50
Graphcool types and queries
mutation {
createUser(name: "Sébastien") {
id
name
}
}
mutation {
createUser(name: "Mary") {
id
@scastiel
scastiel / Makefile
Last active July 4, 2023 12:00
Resources for eBook creating using Pandoc
all: pdf epub kindle html examples
BOOK_TITLE = A\ React\ Developer’s\ Guide\ to\ Hooks\ -\ Sebastien\ Castiel
dist:
@mkdir -p dist
pdf: dist/${BOOK_TITLE}.pdf
@echo '✅ PDF'
<?php
echo "Hello!";
?>
@scastiel
scastiel / SeoHeaders.ts
Last active September 28, 2022 19:55
SeoHeaders.ts
import Head from 'next/head'
export const SeoHeaders = ({
title,
description,
author,
twitterAuthor,
twitterSite,
url,
imageUrl,