Comments (8)
Add
export const GQLMax140Chars = asNexusMethod(
new RegularExpression('Max140Chars', /[\s\S]{0,140}/),
'max140Chars',
);
export const GQLMax1024Chars = asNexusMethod(
new RegularExpression('Max1024Chars', /[\s\S]{0,1024}/),
'Max1024Chars',
);
from este.
Ups. Relay does not support custom scalars mapping. That's bad.
from este.
But we can fix 'any' type generated with Relay manually via mapped types. OK, that's good enough. API integrity is the must.
from este.
But Nexus has the same problem. It generates any type for any custom scalar. That sucks. OK, use default scalars until both Nexus and Relay will support custom scalar TS types generation.
from este.
Oh, Nexus supports custom mapping.
typegenAutoConfig: {
// debug: true,
sources: [{ source: path.join(__dirname, './types.ts'), alias: 'types' }],
contextType: 'types.Context',
backingTypeMap: {
EmailAddress: 'string',
},
},
from este.
Hmm, but Relay does not support it yet and useMutation leverages types for input component fields.
from este.
But we can patch it!
Low priority, but having restricted GraphQL types would be nice.
from este.
Sunsetting.
from este.
Related Issues (20)
- ..
- Can not deploy to now HOT 3
- passwordless email only auth HOT 1
- Relay 4 HOT 1
- Refactor schema HOT 4
- Persist Relay across pages HOT 1
- file-name-casing HOT 2
- Move font smoothing to theme HOT 1
- How to run yarn test in ZEIT Now? HOT 1
- esm 23 and 24 broken HOT 2
- Not able to start the project in development mode HOT 1
- Enforce mandatory return type for TypeScript HOT 1
- Replace KeyboardNavigableView with react-roving-tabindex HOT 4
- Replace KeyboardNavigableView with context and hook HOT 2
- Use assert-never HOT 1
- Simplify FormattedMessage id HOT 1
- Collocate theme styles? HOT 1
- Current status
- update relay version to 5.0 HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from este.