File tree Expand file tree Collapse file tree 3 files changed +18
-4
lines changed Expand file tree Collapse file tree 3 files changed +18
-4
lines changed Original file line number Diff line number Diff line change 1+ /* @flow */
2+
13import { mongooseModelToTypeComposer } from './modelConverter' ;
24
35export default mongooseModelToTypeComposer ;
Original file line number Diff line number Diff line change 1+ /* @flow */
12import toDottedObject from './toDottedObject' ;
3+ import { isObject } from './is' ;
24
35export {
46 toDottedObject ,
7+ isObject ,
58} ;
69
710export function upperFirst ( string : string ) : string {
811 return string . charAt ( 0 ) . toUpperCase ( ) + string . slice ( 1 ) ;
912}
10-
11- export function isObject ( value : mixed ) : boolean {
12- return typeof value === 'object' && ! Array . isArray ( value ) && value !== null ;
13- }
Original file line number Diff line number Diff line change 1+ /* @flow */
2+
3+ export function isString ( value : mixed ) : boolean {
4+ return typeof value === 'string' ;
5+ }
6+
7+ export function isObject ( value : mixed ) : boolean {
8+ return typeof value === 'object' && ! Array . isArray ( value ) && value !== null ;
9+ }
10+
11+ export function isFunction ( value : mixed ) : boolean {
12+ return ! ! ( value && value . constructor && value . call && typeof value === 'function' && value . apply ) ;
13+ }
You can’t perform that action at this time.
0 commit comments