Category "javascript"

Hardhat compile error "Expected a value of type HttpNetworkConfig"

I'm attempting to follow the NFT tutorial here. I have set up the accounts on Alchemy and Metamask created the .sol file. I have a .env file in root that look

Ionic 6 - localization of Google Maps API

I am using Angular 13 and Ionic 6 to add Google Maps API V3. Here is a simple example provided by Google to add the map using TypeScript. When using Ionic, I am

Mongoose and Next.js: Unhandled Runtime Error TypeError: Cannot read properties of undefined (reading 'Token')

I basically defined this Model, much like another which doesn't error out; So I am stumped as to why it's not working... Here is a Minimal, Reproducible Example

Get selected value in dropdown list using JavaScript

How do I get the selected value from a dropdown list using JavaScript? I tried the methods below, but they all return the selected index instead of the value:

Adding array of value in javascript

I'm asking this question again and hope I get the answer this time, I have an array of number that adds and subtract on button click which works withonclick and

How Can i execute something in one window and it happens on another (chrome)

I want to make a GUI which opens in a pop-out window. It needs to be able to access the console from the original window.(aka needs to run commands from pop-out

Unable to map nested array data in JavaScript?

Here, I have nested array object categories which have nested array objectproduct. product contains name, price, discount, unitsold properties with images array

Can't insert an array of data into Formik state. One element is set only

I try to add an array of files into "files" property in Formik state, Formik state: initialValues={{ firstName: '', last

Error: Absolute route path "/" nested under path "/app" is not valid

I suddenly get this error and not sure why. I did not change the "react-router-dom": "^6.0.0-beta.4" version. But the "react-dom": "^16.8.4"" vad changed to "re

Setting state in React useEffect hook

In my app I fetch data from my API after a button is clicked that changes the state of endpoint. Until the data is fetched I want to display a loading icon. Aft

Making changes to an installed node package?

I have an external node package installed in my project. It does 90% of what I want but I'd like to make some changes to it. I don't want to submit a PR to de

What wrong with Vue scroll modal?

Im trying since yesterday find a way to screen a modal on Vuejs, when i scrolling down a page, the problem is i got nothing on my screen when i compile the code

Javascript Transformation Missing Objects

Hi I am transforming objects I have write the following program to add newName in the array If you take a look resultedEvents, categoryName and name is missing

How to use nock in order to mock Firebase/Firestore in NodeJS?

I have a REST API which written in NodeJS. The REST API gets a file and information and then uploads the file to the drive and stores the information inside my

How to Create a Dropdown Menu with Static Items in Ember

I'm very new to JS/Ember and have been able to create a static dropdown menu that functions as desired however I've duplicated the static array of objects that

Simple counters - dataset not working properly

I am working on a site that has a lot of counters and I have a problem getting the [data-speed] to create different counter speeds depending on the number in th

ERR_BLOCKED_BY_RESPONSE.NotSameOrigin CORS Policy JavaScript

This is the image URL I got from an api https://scontent-jnb1-1.cdninstagram.com/v/t51.2885-15/e15/242204298_1728375270686500_5634415857798350440_n.jpg?_nc_ht=s

Bootstrap multi row selection from table data and post to Flask backend

What I want to do is to let my users select multiple rows in a table and them hit a button to send this data back. My JS script file looks has the following: &l

How to make interactive active line when clicked with react

I have 3 lists of a clickable links, so when you click one you go to that section and the line too. so this is my code : <div className="description-containe

ReactJS 17.0.2 seems to call function again when putting value into DOM

There is a strange behavior when running ReactJS 17.0.2. I have a function that generates a random number outside of a component. I assign the return value of t