source: https://github.com/kentcdodds/react-testing-library/pull/307/files
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
var { graphql, GraphQLSchema, GraphQLString, GraphQLObjectType, GraphQLNonNull, GraphQLList } = require('graphql'); | |
// root query | |
const RootQuery = new GraphQLObjectType({ | |
name: 'RootQuery', | |
fields: () => QueryFields, | |
}); | |
const QueryFields = {}; |
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 class="grid g"></div> | |
<div class=""></div> | |
<style> | |
body { | |
background: #6592CF; | |
} | |
.grid { | |
position: absolute; | |
top: 0px; |
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
declare module 'svelte-routing' { | |
import { SvelteComponent, SvelteComponentTyped } from 'svelte'; | |
interface LinkProps { | |
to: string; | |
replace?: boolean; | |
state?: { | |
[k in string | number]: unknown; | |
}; | |
getProps?: (linkParams: GetPropsParams) => Record<string, any>; |
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
{ | |
"dependencies": { | |
"@jaebradley/fruit": "^1.0.20", | |
"@nrwl/cli": "^9.4.1", | |
"@persper/js-callgraph": "^1.3.2", | |
"@storybook/cli": "^5.3.17", | |
"@typescript-eslint/eslint-plugin": "^2.13.0", | |
"cloc": "^2.5.1", | |
"commitizen": "^4.0.3", | |
"conventional-changelog-cli": "^2.0.23", |
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
type ComponentProps<C> = C extends React.ComponentType<infer P> ? P : any; |
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 jMoment from 'moment-jalaali' | |
import { toPersian } from './toPersian' | |
export default class jalaaliUtils { | |
static toJMoment (date) { | |
return jMoment(date ? date.clone() : undefined) | |
} | |
static parse (value, format) { | |
return jMoment(value, format) |
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
@classmethod | |
def mutate_and_get_payload(cls, input, context, info): | |
user = context.user | |
old_password = input.get('old_password') | |
new_password = input.get('new_password') | |
if user.has_usable_password(): | |
if not user.check_password(old_password): | |
raise ResponseError( | |
"Invalid Password", |
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
class ResponseError(Exception): | |
def __init__(self, message, code=None, params=None): | |
super().__init__(message) | |
self.message = str(message) | |
self.code = code | |
self.params = params |
NewerOlder