sudo lsof -i:5000
kill -9 12345
sudo lsof -i:5000
kill -9 12345
| const query = await client.graphQLClient.query(root => { | |
| root.add('node', { | |
| args: { | |
| id: checkoutId | |
| }, | |
| alias: 'checkout' | |
| }, node => { | |
| node.add('id') | |
| node.addInlineFragmentOn('Checkout', Checkout => { | |
| Checkout.add('subtotalPrice') |
| # const { importSchema } = require("graphql-import"); | |
| # importSchema("app/graphql/schema.graphql") | |
| # Fixed | |
| const { | |
| ApolloServer, | |
| gql | |
| } = require("apollo-server-express"); | |
| const fs = require("fs"); | |
| const typeDefs = gql` |
| # const { importSchema } = require("graphql-import"); | |
| # importSchema("app/graphql/schema.graphql") | |
| # Fixed | |
| const { | |
| ApolloServer, | |
| gql | |
| } = require("apollo-server-express"); | |
| const fs = require("fs"); | |
| const typeDefs = gql` |
| directive @isAuth on FIELD_DEFINITION | |
| type Mutation { | |
| addPost(title: String!, content: String! ): Post @isAuth | |
| } |
| # Add timestamp on history | |
| echo 'HISTTIMEFORMAT="%d/%m/%y %T "' >> ~/.bashrc |
I hereby claim:
To claim this, I am signing this object:
| it('mocks search', () => { | |
| delete window.location; | |
| window.location = { search: '?query=phone' }; | |
| expect(window.location.search).toEqual('?query=phone'); | |
| }); |
| const range = (start, end) => | |
| new Array(end - start + 1).fill(undefined).map((_, i) => i + start); |
| import React, { PureComponent } from 'react'; | |
| import { connect } from 'react-redux'; | |
| import { bindActionCreators } from 'redux'; | |
| // actions | |
| import getOldAction from 'actions/getOldAction'; | |
| // component | |
| const App = ({ getOldAction, newAction }) => { | |
| return <div>App</div>; |