Skip to content

Instantly share code, notes, and snippets.

View EmmanuelDemey's full-sized avatar

Emmanuel DEMEY EmmanuelDemey

View GitHub Profile
<!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" href="style.css" />
</head>
<body>
<div id="body">
<header>Header</header>
<nav>Menu</nav>
<main>Main</main>
import d, { Document, EnvelopeDefinition, Recipients, SignHere, Signer, Tabs } from "docusign-esign";
import fs from "fs";
import path from "path";
import { getContractInformationFromRequest } from "../contract/getContractInformation";
import { generateContractWithoutEOF } from "../contract/generateContractPdf";
import { API_ACCOUNT_ID, PROD_API, INTEGRATION_KEY, USER_ID } from "./config";
import { convertContractToBast64 } from "../utils/pdf";
import { generateContractDocumentFileName } from "../contract/generateContractDocumentFileName";
import { generateCarbonCopies } from "./generateCarbonCopies";
@EmmanuelDemey
EmmanuelDemey / TP Aggrégation
Last active April 16, 2024 14:07
Correction Elasticsearch
POST person-manu-v3/_search
{
"size": 0,
"aggs": {
"group_by_year": {
"date_histogram": {
"field": "registered",
"calendar_interval": "1y"
},
[
"{{repeat(3, 3)}}",
{
"isActive": "{{bool()}}",
"balance": "{{floating(1000, 4000, 2, \"$0,0.00\")}}",
"picture": "http://placehold.it/32x32",
"age": "{{integer(20, 40)}}",
"eyeColor": "{{random(\"blue\", \"brown\", \"green\")}}",
"name": "{{firstName()}} {{surname()}}",
"gender": "{{gender()}}",
import { Client } from "@elastic/elasticsearch"
import { readFileSync } from "fs"
(async function(){
const pipeLineName = "asn-demo-node-js";
const documents: any = [{
path: "./dummy.pdf",
name: "Manu"
import "bulma/css/bulma.css";
import { useEffect, useState } from "react";
type Person = {
name: string;
height: string;
mass: string;
hair_color: string;
skin_color: string;
eye_color: string;
import React, { ReactElement, useContext, useEffect } from 'react';
import { useHistory } from 'react-router';
import './ErrorBoundaries.scss';
import { useT } from 'talkr';
const ErrorStatusContext = React.createContext((e: string) => {
//this is intentional
});
// How to use it => const throwError = useAsyncError(); throwError("
import "./App.css";
import { createContext, lazy, useContext, useEffect, useState } from "react";
const Excel = lazy(() => import("./Demo2"));
export const i18nContext = createContext("bouh");
export const I18nContextProvider = i18nContext.Provider;
export const useI18n = () => {
const context = useContext(i18nContext);
{
"issues": [
{
"engineId": "eco-index",
"ruleId": "rule1",
"severity": "BLOCKER",
"type": "CODE_SMELL",
"primaryLocation": {
"message": "fully-fleshed issue",
"filePath": "functions/package.json"
<p id="question">Question</p>
<ul aria-labelledby="question" role="radiogroup">
<li role="radio" aria-checked="false" tabindex="-1">
<img aria-hidden="true" src="radio.svg" alt="Non sélectionné : " />
Choix 1
</li>
<li role="radio" aria-checked="true" tabindex="0">
<img aria-hidden="true" src="radio-checked.svg" alt="Sélectionné : " />
Choix 2
</li>