remove custom Scalar usage example since it's now consistent with other

types
This commit is contained in:
Aron Jones 2016-02-04 16:54:19 -05:00
parent c472bf455e
commit d16155ea17

View File

@ -59,16 +59,6 @@ class DateTime(Scalar):
return datetime.datetime.strptime(value, "%Y-%m-%dT%H:%M:%S.%f") return datetime.datetime.strptime(value, "%Y-%m-%dT%H:%M:%S.%f")
``` ```
Unlike the other basic types, custom `Scalar` types should not be instantiated
when used.
```python
import graphene
class Post(graphene.ObjectType):
created = graphene.Field(DateTime)
```
## Mounting in ClassTypes ## Mounting in ClassTypes
This types if are mounted in a `ObjectType`, `Interface` or `Mutation`, This types if are mounted in a `ObjectType`, `Interface` or `Mutation`,