Skip to main content
The 2024 Developer Survey results are live! See the results

Questions tagged [javascript]

For questions about programming in ECMAScript (JavaScript/JS) and its different dialects/implementations (except for ActionScript). Note that JavaScript is NOT Java. Include all tags that are relevant to your question: e.g., [node.js], [jQuery], [JSON], [ReactJS], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

1 vote
1 answer
12 views

Fix for AMP Error caused by the Imply script tag in nextjs App

Tag found outside the document head which is only allowed as a direct child of the document head. Error: Invalid attribute: data-amp-bind Fix: Ensure that you are using only allowed attributes for AMP ...
Hemant Singh Rajput's user avatar
0 votes
0 answers
6 views

still giving error after using the use client on top in next.js component

× You're importing a component that needs useRouter. It only works in a Client Component but none of its parents are marked with "use client", so they're Server Components by default. "...
vishwas babar's user avatar
-1 votes
1 answer
35 views

How to convert this raw pdf to pdf file

I have an api call which returns raw pdf. I'm storing them in a variable called rawpdf. I want to display that in my webpage. As shown here is the raw pdf file //axios function retrned data %PDF-1.4 %�...
SONIC's user avatar
  • 59
-3 votes
0 answers
39 views

JS promises will run parallelly or one by one

Need to now about the promises , The JS promises will run parallelly or not this is the below code I'm using, Here I am creating three promises and checking the execution time const startTime=Date....
Jesu Jenarath's user avatar
0 votes
0 answers
8 views

How to Close ISWebCombo Dropdown After Selecting a Value with AutoPostback Enabled?

I'm using an ISWebCombo dropdown control in my ASP.NET Web Forms application. The dropdown does not close automatically when I select a value. I need it to close after selection. <ISWebCombo:...
parangat's user avatar
0 votes
0 answers
23 views

Inserting unique attribute to HML tag element in loop

I have a supersite that uses all kinds of js, including backbone.js and underscore.js. On one of of my pages, I have the piece of code below: <#loop:main_tlds_price_add#> <tr> <...
adeguk Loggcity's user avatar
-1 votes
1 answer
13 views

Multiple markers in a loop in the Google-Maps API (JS)

I try to put multiple markers (the new 2024 API) with a loop, on Google Maps, but only the last is shown. My code : let map; async function initMap(center, pk, partner) { const ...
defiraid's user avatar
0 votes
0 answers
12 views

Static import of JSON object specifying the type

I have a small javascript web-application that I develop on my laptop and is later bundled with webpack for publishing. In some files, some JSON-data is imported right in the "header" of the ...
nhaggen's user avatar
  • 369
1 vote
3 answers
45 views

Skip arguments in JS [duplicate]

I have a function example(arg1,arg2,arg3,arg4) and the function uses arg4 for something. Is there a way for me to skip the other arguments instead of having them as unused variables. I tried example(,,...
Tarator Programmmer's user avatar
-1 votes
0 answers
11 views

Screenshotting of SVG D3 diagram with wrong rounding edges

I'm trying to take a screenshot of SVG of my Sankey diagram generated by D3.js in React app. Every time I try to capture it using different libraries and methods, the edges of the links become rounded....
Romanoti's user avatar
  • 1,265
0 votes
1 answer
17 views

Can't use variable field of mongodb in javascript

I have retrieved one document from mongodb, in that I have one array and I want to loop through that array but I can't do that. If I loop through that it consider whole array as one element, this is ...
Just what I like's user avatar
-3 votes
0 answers
26 views

Invalid Client or invalid client credentials [closed]

{ "error": "invalid_client", "error_description": "Invalid client or Invalid client credentials" } I have put everything correct for the basic ...
Muhammad Jamshed's user avatar
1 vote
0 answers
10 views

e.nativeEvent.offsetX is 0 on mouseMove inside setState function

I have the following code that gets the cursor position on a canvas element. The code works fine in Chrome, but in Firefox, the e.nativeEvent.offsetX is 0 inside the set state function and outside is ...
Pantis Calin's user avatar
0 votes
0 answers
7 views

WKWebView accessibility tree not updated after DOM change

I have a simple UIKit app that pushes a view containing a WKWebView. If VoiceOver is enabled, when the view is pushed the OS sets the accessibility focus in the back button of the navigation bar. The ...
rai212's user avatar
  • 751
0 votes
0 answers
13 views

Zod allow all keys matching regex

I'm using zod to validate some data, and I want to allow certain attributes, as well as any attribute with key matching /metadata_hash_.*/. I cannot simply use a record because I am using mixed types, ...
jotjern's user avatar
  • 472

15 30 50 per page