This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
console.log(this); // logs window; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require("dotenv").config(); | |
import { ApolloServer, makeExecutableSchema } from "apollo-server"; | |
import { augmentSchema } from "neo4j-graphql-js"; | |
import gql from "graphql-tag"; | |
import { v1 as neo4j } from "neo4j-driver"; | |
const driver = neo4j.driver( | |
process.env.neo4j_uri!, | |
neo4j.auth.basic(process.env.neo4j_user!, process.env.neo4j_pass!) | |
); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/widgets.dart'; | |
import 'package:flutter_hooks/flutter_hooks.dart'; | |
import 'package:graphql/internal.dart'; | |
import 'package:graphql/client.dart'; | |
QueryResult useQuery( | |
{@required GraphQLClient client, @required QueryOptions options}) { | |
return Hook.use(_QueryHook(client: client, options: options)); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
class FadeOnScroll extends StatefulWidget { | |
final ScrollController scrollController; | |
final double zeroOpacityOffset; | |
final double fullOpacityOffset; | |
final Widget child; | |
FadeOnScroll( | |
{Key key, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'dart:async'; | |
import 'package:ferry/ferry.dart'; | |
import 'package:gql_link/gql_link.dart'; | |
import 'package:gql_exec/gql_exec.dart'; | |
import 'package:gql/ast.dart'; | |
Map<String, List<SelectionNode>> _fragmentMap(DocumentNode document) => { | |
for (var def in document.definitions.whereType<FragmentDefinitionNode>()) | |
def.name.value: def.selectionSet.selections, | |
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Rank | Type | Prefix/Suffix | |
---|---|---|---|
1. | Prefix | my+ | |
2. | Suffix | +online | |
3. | Prefix | the+ | |
4. | Suffix | +web | |
5. | Suffix | +media | |
6. | Prefix | web+ | |
7. | Suffix | +world | |
8. | Suffix | +net | |
9. | Prefix | go+ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
targets: | |
$default: | |
builders: | |
gql_build|schema_builder: | |
enabled: true | |
gql_build|ast_builder: | |
enabled: true | |
gql_build|op_builder: | |
enabled: true | |
options: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
targets: | |
$default: | |
builders: | |
gql_build|schema_builder: | |
enabled: true | |
gql_build|ast_builder: | |
enabled: true | |
gql_build|op_builder: | |
enabled: true | |
options: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'dart:async'; | |
import 'package:ferry/ferry.dart'; | |
import 'package:gql_http_link/gql_http_link.dart'; | |
import 'package:gql_link/gql_link.dart'; | |
import 'package:gql_exec/gql_exec.dart'; | |
import 'package:rxdart/rxdart.dart'; | |
import 'package:firebase_auth/firebase_auth.dart'; | |
import 'package:get_it/get_it.dart'; | |
import '../stores/user_store.dart'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Easier to understand version | |
function addMany(num) { | |
return (next) => { | |
if (next === undefined) { | |
return num; | |
} else { | |
return addMany(num + next) | |
} | |
} | |
} |