{"id":15354121,"url":"https://github.com/srtucker22/graphql-primitive","last_synced_at":"2026-01-30T04:36:06.903Z","repository":{"id":39060219,"uuid":"101110791","full_name":"srtucker22/graphql-primitive","owner":"srtucker22","description":"GraphQL Primitive Scalar Type","archived":false,"fork":false,"pushed_at":"2025-04-03T21:40:59.000Z","size":448,"stargazers_count":1,"open_issues_count":35,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-12T08:04:04.259Z","etag":null,"topics":["graphql","javascript","primitives"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/srtucker22.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2017-08-22T21:54:10.000Z","updated_at":"2020-05-28T13:49:47.000Z","dependencies_parsed_at":"2023-02-01T08:17:00.991Z","dependency_job_id":"71531ff1-a3cc-4b34-83b6-c21da48e9a64","html_url":"https://github.com/srtucker22/graphql-primitive","commit_stats":{"total_commits":98,"total_committers":6,"mean_commits":"16.333333333333332","dds":0.3163265306122449,"last_synced_commit":"d3db8a840dddbb285de13face75b1e76644f0fdf"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/srtucker22%2Fgraphql-primitive","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/srtucker22%2Fgraphql-primitive/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/srtucker22%2Fgraphql-primitive/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/srtucker22%2Fgraphql-primitive/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/srtucker22","download_url":"https://codeload.github.com/srtucker22/graphql-primitive/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248537141,"owners_count":21120709,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["graphql","javascript","primitives"],"created_at":"2024-10-01T12:17:35.089Z","updated_at":"2026-01-30T04:36:01.884Z","avatar_url":"https://github.com/srtucker22.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# graphql-primitive [![Npm version](https://img.shields.io/npm/v/graphql-primitive.svg)](https://www.npmjs.com/package/graphql-primitive) [![Build Status](https://travis-ci.org/srtucker22/graphql-primitive.svg?branch=master)](https://travis-ci.org/srtucker22/graphql-primitive) [![Coverage Status](https://coveralls.io/repos/github/srtucker22/graphql-primitive/badge.svg?branch=master)](https://coveralls.io/github/srtucker22/graphql-primitive?branch=master)\n\n## A GraphQL Primitive Scalar Type\n\n* [Overview](#overview)\n* [Installing](#installing)\n* [Usage](#usage)\n* [Contributing](#contributing)\n* [Licence](#licence)\n\n## Overview\n\nGraphQL Primitive Scalar is a scalar that accepts the following Javascript primitives:\n\n* String\n* Number\n* Boolean\n* undefined\n* null\n\nEver wanted to accept or send multiple primitives in GraphQL? :)\n\n## Installation\n\n```bash\nnpm i graphql-primitive\n```\n\n## Usage\n\n```js\nimport { makeExecutableSchema } from 'graphql-tools';\nimport GraphQLPrimitive from 'graphql-primitive';\n\nconst schemaString = `\nscalar Primitive\ntype Foo {\n  aField: [Primitive] # an array of String | Int | Boolean | undefined | null\n}\ntype Query {\n  foo: Foo\n}\n`;\n\nconst resolveFunctions = {\n  Primitive: GraphQLPrimitive\n};\n\nconst jsSchema = makeExecutableSchema({\n  typeDefs: schemaString,\n  resolvers: resolveFunctions\n});\n```\n\n## Contributing\n\nThis project welcomes code contributions, bug reports and feature requests. Please see the guidelines in [CONTRIBUTING.md](CONTRIBUTING.md) if you are interested in contributing.\n\n## License\n\nMIT License\n\nCopyright (c) 2017 Simon Tucker\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsrtucker22%2Fgraphql-primitive","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsrtucker22%2Fgraphql-primitive","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsrtucker22%2Fgraphql-primitive/lists"}