Skip to content

Instantly share code, notes, and snippets.

View yleflour's full-sized avatar

Yann Leflour yleflour

View GitHub Profile
diff --git a/node_modules/typeorm/persistence/subject-builder/OneToManySubjectBuilder.js b/node_modules/typeorm/persistence/subject-builder/OneToManySubjectBuilder.js
index 43fb09e..b62e654 100644
--- a/node_modules/typeorm/persistence/subject-builder/OneToManySubjectBuilder.js
+++ b/node_modules/typeorm/persistence/subject-builder/OneToManySubjectBuilder.js
@@ -145,10 +145,11 @@ var OneToManySubjectBuilder = /** @class */ (function () {
parentSubject: subject,
canBeUpdated: true,
identifier: removedRelatedEntityRelationId,
- changeMaps: [{
- relation: relation.inverseRelation,
@yleflour
yleflour / wallaby.js
Last active September 2, 2020 19:30
Wallaby + React Native
/*
WallabyJS React Native Config
Works well with Jest + Enzyme
*/
/* eslint-disable */
module.exports = function (wallaby) {
return {
files: [
'src/**/*.js',
@yleflour
yleflour / callback-promises-async.ts
Created February 7, 2022 09:09
Callback / Promises / Async
// Callback
const asyncPowWithCallback = (arg1, timeout, callback: (error, value) => void) => {
setTimeout(() => {
callback(null, arg1*arg1);
}, timeout);
}
const value = asyncPowWithCallback(2, 100, (error, value) => {
console.log("value1");
});
import React, { useContext } from "react";
import { createContext } from "react";
export const contextFactory = <TParams, TStore>(useStore: (args: TParams) => TStore) => {
const Context = createContext<TStore>(null as TStore);
const useStoreContext = () => useContext(Context);
const Provider = (
props: