Title: Positive, Negative constraints to be used with String scalar type · Issue #56 · graphql-java/graphql-java-extended-validation · GitHub
Open Graph Title: Positive, Negative constraints to be used with String scalar type · Issue #56 · graphql-java/graphql-java-extended-validation
X Title: Positive, Negative constraints to be used with String scalar type · Issue #56 · graphql-java/graphql-java-extended-validation
Description: We have a use-case where we define numeric values as String scalar in the graphql schema. the reason for that is not to loose precision for fractions. We use them effectively as BigDecimal. The problem with this is that we cannot use Pos...
Open Graph Description: We have a use-case where we define numeric values as String scalar in the graphql schema. the reason for that is not to loose precision for fractions. We use them effectively as BigDecimal. The pro...
X Description: We have a use-case where we define numeric values as String scalar in the graphql schema. the reason for that is not to loose precision for fractions. We use them effectively as BigDecimal. The pro...
Opengraph URL: https://github.com/graphql-java/graphql-java-extended-validation/issues/56
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Positive, Negative constraints to be used with String scalar type","articleBody":"We have a use-case where we define numeric values as String scalar in the graphql schema. the reason for that is not to loose precision for fractions. We use them effectively as BigDecimal.\r\n\r\nThe problem with this is that we cannot use Positive, Negative and other constraints as they are only applicable on numeric values.\r\n\r\nI tested locally and looking at the code `AbstractPositiveNegativeConstraint` could easily handle String scalar type by code: `AbstractDirectiveConstraint#asBigDecimal()` can cope with String. \r\n\r\nThe only thing would need to be changed is adding String to `AbstractPositiveNegativeConstraint#getApplicableTypes`\r\n\r\nWe could use `BigDecimal` scalar unit in our schema, but we'd like to avoid forcing our client to set up extra configuration on their side of graphql code generation\r\n\r\nWould it be ok if I create such pull request to support String generally for all numeric kind of constraints?","author":{"url":"https://github.com/pkonyves","@type":"Person","name":"pkonyves"},"datePublished":"2022-01-13T10:46:21Z","url":"https://github.com/graphql-java/graphql-java-extended-validation/issues/56"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:dbfb61ab-4995-7c8e-9ec1-eaf633ab3bf8 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | C80E:1D20B7:1A6F334:2174FC2:6B01866E |
| html-safe-nonce | 8319b7d68d3abafea151bf67fbd1755e311e5761d8f92499f9c1d4adb4dd0d1c |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDODBFOjFEMjBCNzoxQTZGMzM0OjIxNzRGQzI6NkIwMTg2NkUiLCJ2aXNpdG9yX2lkIjoiMzIzOTgzNzgzMDUzNjU5NTA1NCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 837d05b4bc755e1b714e253b015c5a18c1481522aec1378fd1ebdda24157602e |
| hovercard-subject-tag | issue:1101527578 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/graphql-java/graphql-java-extended-validation/56/issue_layout |
| twitter:image | https://opengraph.githubassets.com/f92b15602b8d1251a3a11fd94d18c3b48259e62a328031cad35d7cf7c338765c/graphql-java/graphql-java-extended-validation/issues/56 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/f92b15602b8d1251a3a11fd94d18c3b48259e62a328031cad35d7cf7c338765c/graphql-java/graphql-java-extended-validation/issues/56 |
| og:image:alt | We have a use-case where we define numeric values as String scalar in the graphql schema. the reason for that is not to loose precision for fractions. We use them effectively as BigDecimal. The pro... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | pkonyves |
| hostname | github.com |
| expected-hostname | github.com |
| None | cc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c |
| turbo-cache-control | no-preview |
| go-import | github.com/graphql-java/graphql-java-extended-validation git https://github.com/graphql-java/graphql-java-extended-validation.git |
| octolytics-dimension-user_id | 14289921 |
| octolytics-dimension-user_login | graphql-java |
| octolytics-dimension-repository_id | 205507809 |
| octolytics-dimension-repository_nwo | graphql-java/graphql-java-extended-validation |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 205507809 |
| octolytics-dimension-repository_network_root_nwo | graphql-java/graphql-java-extended-validation |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 8c77c9e8439031ad54c75a250694842892f693e1 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width