Category "javascript"

why does adding sanity to my react frontend blank the whole localhost:3000 out?

I have my code set up like this with two folders one backend_sanity and the other frontend_react and i can not get the sanity to link to my react front end with

Firebase/auth import source-map warnings

I am building a react app with firebase library v7.15.5 and when I'm importing 'firebase/auth', it works fine but it throws me warnings in a terminal: WARNING i

iterate through complex nested json array javascript

nested json structure Json Structure: { "id": "30080", "dataelements": { "Name": "abc", }, "children": [ {

How to remove property from object

We have an array of objects like this: const arrOfObjects = [ { name: 'Ronaldo', age: 20, status: true }, { name: 'Messi', age: 30,

How to make "scroll drag area" bigger [closed]

I have a drag and drop table and when I want to drag an element from the top to bottom of the table I have to drag it to the "bottom area" of

How to click on the reCAPTCHA using webdriverio

Hi everyone can you help me with that problem? I'm trying to enter inside the iframe of google reCAPTCHA. Tried several ways to click but didn't work with the i

Validate form selection option custom input base on product type EDIT

So I think my last question wasn't cleared. Currently I am doing form validation for my project. I have form input with main field of "sku", "name", and "price"

getting total size of ArrayDataProvider

I am using a knockout computed function to update a list with a filter based on inputs from user. This list has some predefined data, and when the filter is app

Only getting RangeError when Chrome Developer Tools is closed

So I have this weird error where the script stops executing with RangeError: Maximum call stack size exceeded when I launch it normally, but when I open the Dev

Typescript auto-complete not working in VSCode

I'm trying to make use of Puppeteer within a ts file which works fine except the VSCode Intellisense stops working a soon as I'm inside a .ts and not a .js file

webpack < 5 used to include polyfills for node.js core modules by default. This is no longer the case

im getting the errors: 22 errors have detailed information that is not shown. Failed to compile. webpack < 5 used to include polyfills for node.js core modul

How does an async function called with await can block the event loop?

In the following code, the 'Hey, timeout executed!' is only printed after the loop in the longLoop function is finished. setTimeout(() => console.log('Hey, t

Getting "Cannot set headers after they are sent to the client" error in Express [closed]

Screenshot of the error: Code of client side: jwt attached api: Here's the jwt verifying function: const authHeader = req.headers?.auth

Change structure of particular array in javascript

Unfortunately, due to a plugin that I'm using, I have to serialize form names and values in a particular format for them to be saved in a database. Say I have t

Check within 3 variables that 3 specified values are held, in any order but not doubled up

I'm trying to code a function into my card game to check if the first 2 cards hold any 2 out of the following 3 values: 6, 7 or 8 i.e. 6&7, 7&8, or 6&am

change even character in string with the for loop

hello everyone please i'am a begginer in javascript and i found this challenge , but i don't know how to solve it let str1 = "javascript"; // Example output:

How to convert some Nuxt code into some Vue?

How can I convert this Nuxt script into a Vue compatible one? <script> export default { components: { FeaturedProduct }, async asyncData({ $axio

Prototype members

What is the difference if we define a method in the constructor function or we define it in the prototype of the constructer? I know that if we define it in the

Import .svg and resize .svg use styled-components in next.js

I am currently trying import .svg into next.js project but I failed. I tried import .svg same way as in react project, that I created typing.d.ts and import svg

routers and components in vue.js

My component information is not displayed!!! the router is working great and I test it to many times but there is nothing in components when I run the project.