Comment by Ale TheFe on How to handle API error with a manual retry button...
I'm not sure about what refetch does, but I'd probably go with a useLazyQuery in the error component to have your desired behavior. function IsError() { const [refetch] = useLazyGetUsersQuery(); return...
View ArticleHow to perform a query with where against a public collection in Firestore...
I have a ruleset in Firestore Security Rules defined in this way:rules_version = '2';service cloud.firestore { match /databases/{database}/documents { function isUserAllowed(root, metric) { return...
View ArticleAnswer by Ale TheFe for How to perform a query with where against a public...
I finally ended up modifying mu ruleset in this way, and it works:rules_version = '2';service cloud.firestore { match /databases/{database}/documents { function isUserAllowed(root, metric) { return...
View ArticleWhy NPM CLI creates two identical tokens?
I was trying the NPM cli and I ran 2 times the command npm create token --read-only after having logged in. The result is that now I have 2 completely identical tokens that I'm not able to manage,...
View ArticleHow to authenticate and fetch events from Google Calendar with Firebase and...
As per title, I have a web app built with flutter. I want to authenticate the user with Google and then fetch from the user's Google Calendar the events. I also use Firebase Authentication. I have...
View ArticleComment by Ale TheFe on Flutter - How to center widget inside list view
Much better solution than the accepted one!!
View ArticleWhy NPM CLI creates two identical tokens?
I was trying the NPM cli and I ran 2 times the command npm create token --read-only after having logged in. The result is that now I have 2 completely identical tokens that I'm not able to manage,...
View ArticleHow to connect to a server via Node TLS without knowing the certificate?
Me and a friend of mine have a game deployed on a Ubuntu server. It's a game that we play from the command line, and we connect via openssl s_client -connect <address> <port>. In this way...
View ArticleAnswer by Ale TheFe for How to connect to a server via Node TLS without...
By reading the Node TLS documentation, you can see that the dev must include the server certificate in order to work, by doing:const options = { // Necessary only if the server requires client...
View ArticleHow not to make a ReactJS app freeze when a huge number of docs arrive from a...
I've a ReactJS application made up of 3 simple elements: 2 numbers and an input text. This is a test page of course.The 2 numbers refers to the number of elements that are present in 2 separate...
View ArticleComment by Ale TheFe on How to deploy a Vue Storefront 2 app on a self hosted...
I know that nginx is needed but that's not the point. If I want to deploy a traditional nuxt app I just upload the .nuxt folder, the package.json, I run yarn install and then yarn start. In this case...
View ArticleHow to create a shared set of custom color names in flutter?
I'm using Flutter 3.22 and I have started, for the first time in years, to create my personal library of reusable widgets and utilities.Everything is going well, except for a thing that I'm not getting...
View ArticleComment by Ale TheFe on Flutter GetX - How to manage controller deletion?
It's exactly what I thought but for some reason it's not working. I'm gonna do a deep dive!
View ArticleComment by Ale TheFe on Why do yarn.lock and installed versions diverge?
"Chrome" was just to say "a browser". Yes, I'm editing the package.json directly, shouldn't I? I don't use ~6.1.0 because I know that 6.1.0 is the version I need. And yarn why tells me that my deps...
View ArticleHow to parallel run multiple npm scripts in rollup watch mode using yarn...
I have a React multimodule project.Every module is built with rollup and has its commands defined as"build": "rollup -c","watch": "rollup -cw"From the main package.json I have this scripts...
View ArticleHow to escape HTML special characters when rendering a PDF using EJS and...
I have an express application that generates pdf documents. I use ejs as a template engine and then I use wkhtmltopdf.ejs.renderFile( path.join(__dirname, 'pages', 'lettera.ejs'), { ...some variables...
View ArticleHow to import files from other packages in a multimodule project?
I have a Node multi-module project. I have a shared package whose name in is @company-name/shared. In another module, let's call it myPackage I want to import the test utility files that the shared...
View ArticleHow to correctly handle blur and focus in React Native Navigation?
I have a screen in a React Native app which is made by 2 tabs. Everytime I switch tab I want to initiate a polling operation with my server to get the content of the tab. I'm achieving this by...
View ArticleWhy one of the 2091 BLE Descriptors isn't getting its value on my ESP32...
I'm developing a BLE application using a ESP32-WROOM-32.Everything works great, but there's a strange behavior that I can't address: I have 5 characteristics, 4 are read-only and one is write-only....
View Article