Questions tagged [relayjs]

Relay is a JavaScript framework for building data-driven React applications

Filter by
Sorted by
Tagged with
0 votes
0 answers
14 views

Android Studio: Imported Figma UI Package via Relay Plugin, but UI Package Not Visible in Android View

I am facing an issue after importing a Figma UI package into Android Studio using the Google Relay plugin. The UI package seems to have been successfully imported, but it is not visible in the Android ...
0 votes
0 answers
32 views

Figma Relay Import Error Transformation Error

I attempted to import some themes that were on figma into my android studio using Relay. When importing, I put in my link and left the theme as: androidx.compose.material3.MaterialTheme I got an error ...
12 votes
1 answer
730 views

Is it possible to output simplified Typescript types in the compiled distribution of a Node module

I am trying to create more simplified output in the *.d.ts typescript files which are included with the bundled version of my modules code. These files are generated through a chain involving the ...
0 votes
1 answer
41 views

When using GraphQL and Relay and Fragment, how to see the data?

I am onto Step 4 of the Relay Tutorial at: https://relay.dev/docs/tutorial/fragments-1/ It was strange because when I don't use Fragment, and have the following code: const NewsfeedQuery = graphql` ...
0 votes
0 answers
14 views

When is node query called? Node resolver should be implemented on server?

Background I read Which relay objects must implement Node? page. I could not understand about "diffing" process. Questions Does Relay use node query instead of a query designated by ...
0 votes
2 answers
79 views

Why does useLazyLoadQuery() appear to be like blocking and can cause a re-render?

I am following the tutorial of Relay and it is Step 3, as on https://relay.dev/docs/tutorial/queries-1/. The code with my debugging, is export default function Newsfeed() { console.log("HERE 0&...
47 votes
13 answers
146k views

Lodash debounce with React Input

I'm trying to add debouncing with lodash to a search function, called from an input onChange event. The code below generates a type error 'function is expected', which I understand because lodash is ...
2 votes
1 answer
46 views

how can I use partial data with relay?

I recently start to learn relay and have a question about how I can use partial data with relay. // Screen A const ProductsPageQuery = graphql` query products_PageQuery { products(first: 5,...
0 votes
1 answer
33 views

fault input ESP32 showing

I am using the capacitive sensor to detect an object. The sensor required 24V to operate but ESP32 runs on 2.2 to 3.6V.The input from sensor also gonna be 24V. so I can't directly connect sensor to ...
0 votes
0 answers
19 views

GraphQL Relay mutation with spread fragment selection does not update state after commit

I have this todos-list component import { Suspense } from "react"; import { graphql, useFragment, useLazyLoadQuery } from "react-relay"; import { todosQuery } from "./...
0 votes
0 answers
35 views

Handle typing with data spread between main query and fragment reference in abstracted React components

Based on the example of Relay, it seems trivial to implement a list that read the data from the main query and extract the fragment data from the story ref. Relay example However, if we add a level ...
1 vote
1 answer
2k views

Can't click New/Import UI Packages

I installed Relay plugin for Figma and Android Studio, configured it as in manual. I open Android Studio and can't tap on menu New/Import UI Packages. This button is disabled. Button is disabled I ...
1 vote
1 answer
1k views

How to call multiple mutations at the same time?

I have an array of ids, and I created a mutation that allow me to delete an item using only 1 id. Is there any way to call this mutation multiple times using Relay.Store.commitUpdate or this.props....
0 votes
2 answers
11k views

GraphQL validation error

I am trying out relay-treasure hunt tutorial but getting the following error when I run npm start. I did update my schema by running npm run update-schema. Uncaught Error: GraphQL validation error ``...
0 votes
0 answers
19 views

Received emails from remote IP addresses and store them in a folder for processing and relay emails sent from local server

I hope you are doing well. I am VERY NEW to PostFix. I have a question and I am going round and round in a circle. I would like to be able to accept all emails coming from remote IP addresses. When ...
0 votes
0 answers
20 views

How do you find the window size/response time of a kiln?

I am using this [libray]((https://github.com/imax9000/Arduino-PID-Library/blob/master/examples/PID_RelayOutput/PID_RelayOutput.ino)for my PID controller and I just don't understand how to find the ...
2 votes
1 answer
117 views

How to convert the data retrieved by GraphQL + Relay to normal React state?

Example from the documentation: import type {AppQueryType} from 'AppQueryType.graphql'; const React = require('React'); const {graphql, useQueryLoader, usePreloadedQuery} = require('react-relay'); ...
0 votes
0 answers
50 views

Update Relay Store from data saved on cache for Offline mode

I'm developing a React native app, and want to restore data saved on cache when the user opens the app again, but it's offline. I was able to get the latest store by using store.getSource() and save ...
3 votes
3 answers
907 views

How to implement Relay node query with GraphQL federation

We are trying to implement Relay node query with Apollo federation. Since Apollo is not aware of Relay, we have to implement the node query in some service (Node Resolution Service) interface Node { ...
0 votes
2 answers
709 views

Relay ConnectionHandler.getConnectionID() connection does not exist error

I'm trying to cleanup relay graphql flow in my app. Atm in some places I'm still using fetchKey and record invalidation, which I'd like to change to @appendEdge/@appendNode directives. Unfortunately ...
0 votes
1 answer
90 views

Relay compiler failing to read graphQL file

I am trying to get Relay up and running for the first time and have followed the set up guide at https://relay.dev/docs/getting-started/step-by-step-guide/ I have got as far as generating my graphQL ...
-1 votes
1 answer
28 views

NextJS: How do I statically render a page, but then update with user-specific information once rendered

I'm after some guidance on a particular data fetching use-case with NextJS static page rendering. We have a page that displays articles (imagine something like this page). The data is the same for ...
1 vote
1 answer
68 views

Using React, React Router, and React Relay which should I use to store and retrieve state?

I'm currently using React with React Router and React Relay. Each of these has ways of updating/passing data. React with useState, React Router with it's pushState wrapper (location.state), and Relay ...
0 votes
1 answer
69 views

React Navigation doesn't render route if useLazyLoadQuery is called

I have a very basic react-navigation and relay setup. The data is loaded and the console.log outputs the data, but the View and Text are not rendered and I only see a blank screen. const HomeScreen = (...
0 votes
1 answer
128 views

One huge GraphQl query for all page components instead of multiple single queries - what about navigation and already loaded data?

Imagine a main page at url path / with components ComponentA, ComponentB and ComponentMain. So maybe something like this: Instead of ComponentA, ComponentB and ComponentMain each making a single ...
0 votes
0 answers
207 views

Getting an error like you forgot to wrap the component in provider

I have the below component like a wrapper, and the code looks like as below, export const Wrapper: FC<{ children: ReactNode }> = ({ children }) => ( <StrictMode> <GlobalStyle /&...
1 vote
0 answers
56 views

Setting Cookies from incoming request to outbound fetch() call in NextJS via Relay

I'm using the latest version of NextJS (the one with App router) and integrating it with React-Relay. I have to pass in the Cookie that I get from the browser to the outbound request to my api server. ...
9 votes
3 answers
4k views

How to get the Model ID in the Graphene Django Relay query?

How to receive the native Model ID that stored in the DB (eg. django model ID) when we are executing the Relay query? The main issue that the Relay defines it's own ID so I'm not sure how can we ...
0 votes
0 answers
34 views

How to handle coupon-verification with Relay

I'm having trouble with a seemingly trivial use-case: Assume there is a large checkout page with a 'coupon' field and an 'apply' button next to it. The user enters a coupon code and presses 'apply' ...
0 votes
0 answers
161 views

How do we get Exchange online to identify Sendgrid messages as TreatMessagesAsInternal?

Using Sendgrid as an SMTP relay for Exchange in order to avoid the basic auth deprecation. Currently when Exchange sees a message sent by Sendgrid it identifies it as external sender. These emails ...
3 votes
0 answers
173 views

Relay and Apollo Client both can be used?

I'm developing a front-end with Next.js where GraphQL will be processed from GraphQL API endpoint. Hasura is being used as Back-end. One of my colleague told me that some developers use Relay along ...
2 votes
1 answer
367 views

What's the difference between <fragment_name >$key and <fragment_name >$data in react relay fragment?

I'm learning react relay library, when reading doc Relay - A Guided Tour - Fragments, I am confused by this part: Relay will automatically generate Flow types for any declared fragments when the ...
0 votes
0 answers
21 views

How to fetch 2 fragments (1 is re-fetchable) sequentially

I am new to Relay and currently trying to build an address form that includes 2 drop-downs: a list of countries a list of states in the selected country For simplicity the component can be like this ...
-1 votes
1 answer
87 views

GraphQL/Relay - How to pass a mutation's input variable into a query on the mutation response?

Given a mutation like this (see how nextArticle needs an ID passing): mutation markArticleCompleteMutation( $input: markArticleCompleteInput! ) { markArticleComplete(input: $input) { ...
0 votes
0 answers
39 views

To relay TCP packets?

I've created a server that relays TCP packets with node.js for RDP mediation, but I'm getting the following error. What could be the problem? Relaying port 80 to the website works fine. The error TCP ...
1 vote
1 answer
2k views

GraphQL: creating directives with string comparison

I'm looking to create a GraphQL query that selectively adds/removes fields based on a variable "type", which is a string: query ResultsPage($casetype: String!) According to the reference on ...
0 votes
1 answer
292 views

How do I run relay-compiler as an offline build step, when my GraphQL schema is auto-generated by postgraphile (in its own container) at runtime?

I'm building a web app whose file structure looks something like this: db/ Dockerfile init/ 00-init.sql graphql/ Dockerfile app/ Dockerfile package.json bin/ www public/ ...
0 votes
2 answers
58 views

UI is not updating after record is deleted in GraphQl typescript

Im using Graphql in rails. When I delete a Bicycle it doesn't update in UI I have to refresh my page in order to make the Bicycle go. This is my Query: const [commitDelete, isInFlight] = useMutation&...
2 votes
2 answers
571 views

Is Numb Turn server not working or are my configurations wrong?

I am using the free TURN server provided by https://numb.viagenie.ca/. The STUN servers are also public. I am using the following configuration: const iceConfiguration = { iceServers: [ { ...
0 votes
1 answer
185 views

Hotchocolate 13: Mutation does not work with schema first approach

I am trying to use hotchocolate 13. I have declared a simple mutation as below and have used 'AddGlobalObjectIdentification' to configure relay schema. I have used schema first approach and the ...
180 votes
6 answers
31k views

What is the difference between Falcor and GraphQL?

GraphQL consists of a type system, query language and execution semantics, static validation, and type introspection, each outlined below. To guide you through each of these components, we've ...
6 votes
1 answer
543 views

How do I use the React-Relay @appendNode directive with Hasura's generated functions/schema?

I am currently trying to create an interface wherein a user is able to append additional metadata descriptors to an object while in a modal and need to reflect the results of this append elsewhere on ...
0 votes
2 answers
152 views

Relay Framework uncaught TypeError: this.props.relay.commitUpdate is not a function

I am learning Relay framework and GraphQL. I am following the tutorial from its official website. In that tutorial, I would build a game using GraphQL mutations. The goal of the game is to find a ...
0 votes
3 answers
2k views

Force refetch in Relay Modern RefetchContainer with no (new) variables

I'm trying to find out how/if it is possible to trigger a refresh in a Relay Modern RefreshContainer without passing (new) variables? I’m looking for the best way to implement the good ol’ pull-to-...
0 votes
0 answers
65 views

react-relay apply @include directive automatically

Is there a way to automatically apply the @iclude directive to a fragment if it was imported using a custom import helper? Example: const Feature = importCond('AB_TEST', () => import('./Feature')); ...
0 votes
1 answer
41 views

Why is edges plural in the relay specification?

Here is an example of a graphql query. A person has multiple hats, person{ hats{ color } } Using the relay specification, https://relay.dev/graphql/connections.htm, this query becomes ...
0 votes
0 answers
66 views

Cursor based pagination spec is inefficient

I am looking cursor based pagination https://relay.dev/graphql/connections.htm#ApplyCursorsToEdges() The ApplyCursorsToEdges function initializes edges to contain all edges. However, if we are using a ...
0 votes
0 answers
16 views

How to set postfix serverA sending mails for post postfix serverB, serverC

I want to use postfix at my serverB (fictive ip: 1.2.3.4) and postfix at my serverC (fictive ip: 5.6.7.8) to send all its outgoing mails via my postfix at my serverA (fictive ip: 120.230.140.150), so ...
0 votes
0 answers
38 views

CCS811 Gas sensor With raspberry pi and a relay

dears stackoverflow community, I need an instructions guide with python script to make a project to measure the co2 concentration in room and when the concentration is high the relay should switch a ...
0 votes
1 answer
158 views

Numato Ethernet Relay Module telnet in c#

I'm creating a windows desktop app (c#) and trying to send telnet command to toggle switch on/off ethernet relay when clicking the "ON" button. the problem is that when I click the button ...

1
2 3 4 5
28