Last active
March 29, 2018 15:02
-
-
Save tibotiber/33daaaafae7e90dc5cf616a9e21e834f to your computer and use it in GitHub Desktop.
This file contains hidden or 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
const interfaces = { | |
Character: { | |
__resolveType (obj) { | |
// resolve the type of the incoming interface data | |
if (obj.primaryFunction) { | |
return 'Droid' | |
} else { | |
return 'Human' | |
} | |
} | |
} | |
} | |
module.exports = { interfaces } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment