This file contains 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
(function($, undefined) { | |
/** | |
* Unobtrusive scripting adapter for jQuery | |
* | |
* Requires jQuery 1.6.0 or later. | |
* https://github.com/rails/jquery-ujs | |
* Uploading file using rails.js | |
* ============================= |
This file contains 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
<div id="toolbar"> | |
<iframe id="toolBarPcFrame" src="http://192.168.240.36:8080/ets/ToolBarPcServlet" allowtransparency="true" | |
background-color="transparent" | |
style="position: fixed; z-index: 2147483640; width: 140.4px; height: 146.4px; margin: 0px; padding: 0px; bottom: 0px; right: 0px; border: none;"> | |
<html> | |
<head> | |
<meta name="viewport" | |
content="width=device-width; initial-scale=1.0; maximum-scale=1.0; minimum-scale=1.0; user-scalable=0;"> | |
<meta name="format-detection" content="telephone=no"> | |
<style type="text/css"> |
This file contains 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
// This gist is a draft solution for extending graphQL schemas generated by graffiti. | |
import { getSchema, addMongooseModel, getGQType, getExistedType } from 'lib/graffiti-mongoose/src/schema/schema2'; | |
import { User } from 'app/_schema/mongoose/user'; | |
import { Cv } from 'app/_schema/mongoose/cv'; | |
import { UserData } from 'app/_schema/mongoose/userData'; | |
import ExtraFieldsWrapper from 'lib/graffiti-mongoose/src/wrappers/extra-fields'; | |
import getFieldList from 'lib/graffiti-mongoose/src/query/projection'; |
This file contains 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
mutation { | |
deleteMovie(input: {clientMutationId:"123", id:"TW92aWU6NTZiODc5M2E4NzMwNzYxMjAwMGZhNWM2"}) { | |
clientMutationId | |
id | |
changedMovie { | |
id | |
title | |
} | |
changedMovieEdge { | |
cursor |
This file contains 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
/* eslint-disable prefer-template, arrow-body-style */ | |
import 'whatwg-fetch'; | |
// import fetchWithRetries from 'fbjs/lib/fetchWithRetries'; | |
class AuthError extends Error {} | |
/** | |
* Rejects HTTP responses with a status code that is not >= 200 and < 300. | |
* This is done to follow the internal behavior of `fetchWithRetries`. |
This file contains 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
/** | |
* Composes single-argument functions from right to left. The rightmost | |
* function can take multiple arguments as it provides the signature for | |
* the resulting composite function. | |
* | |
* @param {...Function} funcs The functions to compose. | |
* @returns {Function} A function obtained by composing the argument functions | |
* from right to left. For example, compose(f, g, h) is identical to doing | |
* (...args) => f(g(h(...args))). | |
*/ |
This file contains 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
src/utilities/buildASTSchema.js:257 | |
257: locations: directiveAST.locations.map(node => node.value), | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call of method `map` | |
257: locations: directiveAST.locations.map(node => node.value), | |
^^^^^^^^^^ some string with unknown value. Property not found in | |
97: locations: Array<DirectiveLocationEnum>; | |
^^^^^^^^^^^^^^^^^^^^^ object literal. See: src/type/directives.js:97 | |
src/utilities/buildASTSchema.js:258 | |
258: args: makeInputValues(directiveAST.arguments), |
This file contains 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 React from 'react'; | |
import Relay from 'react-relay'; | |
import { relayStore } from 'app/clientStores'; // relayStore = Relay.Store; | |
import App from 'app/_components/App/App'; | |
import Menu from 'app/Menu/Menu'; | |
import MainPage from 'app/MainPage/MainPage'; | |
import Page404 from 'app/_components/Page404/Page404'; | |
import LoadingPage from 'app/_components/LoadingPage/LoadingPage'; | |
import BrokenPage from 'app/_components/BrokenPage/BrokenPage'; |
This file contains 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
/* eslint-disable no-use-before-define, camelcase */ | |
import cp from 'child_process'; | |
import fsExtra from 'fs-extra'; | |
import hashFiles from 'hash-files'; | |
import chalk from 'chalk'; | |
import { | |
repositoryName, | |
rootDir, | |
buildEnv, |
This file contains 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
let relayStore; | |
function relayCreateStore() { | |
const env = new Relay.Environment(); | |
env.injectNetworkLayer(new Relay.DefaultNetworkLayer('/graphql')); | |
if (__DEV__) { | |
RelayNetworkDebug.init(env); | |
} | |
env.reset = () => relayCreateStore(); | |
env.mutate = ({ | |
query, |
OlderNewer