fork of hey-api/openapi-ts because I need some additional things
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

at feat/use-query-options 31 lines 724 B view raw
1import type { PyNodeBase } from '../base'; 2import type { PyExpression } from '../expression'; 3import { PyNodeKind } from '../kinds'; 4 5export interface PyAssignment extends PyNodeBase { 6 kind: PyNodeKind.Assignment; 7 target: PyExpression; 8 type?: PyExpression; 9 value?: PyExpression; 10} 11 12export function createAssignment( 13 target: PyExpression, 14 type?: PyExpression, 15 value?: PyExpression, 16 leadingComments?: ReadonlyArray<string>, 17 trailingComments?: ReadonlyArray<string>, 18): PyAssignment { 19 if (!type && !value) { 20 throw new Error('Assignment requires at least type or value'); 21 } 22 23 return { 24 kind: PyNodeKind.Assignment, 25 leadingComments, 26 target, 27 trailingComments, 28 type, 29 value, 30 }; 31}