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.
javascript
2,533,918
questions
0
votes
4
answers
2k
views
React Hook "useRef" cannot be called inside a callback error
I'm trying to write Reactjs code for scroll to functionality. I want the referenced IDs of different sections be generated for the elements of the 'lables' array.
import { useRef } from 'react';
...
0
votes
0
answers
17
views
Html not loaded even after window.addEventListener('load', do_something) is invoked
I'm working on a browser extension that scrapes data from a webpage. I've added a method to scrape data, which is invoked via a load listener:
window.addEventListener('load', scrapeSomething)
However, ...
0
votes
1
answer
14
views
Heatmap drilldown is not drilling down correctly and not changing xAxis
I am trying to drilldown my heatmap. The drilldown is not working correctly. The xAxis is remaining the same.
My code:
// Substring template helper for the responsive labels
Highcharts.Templating....
2
votes
1
answer
69
views
How to set background color to transparent with Phaser 3
Trouble
I added two Text objects to a scene.
But for the latter one, I couldn't set background color to transparent.
Can anyone help me?
Here is the screenshot.
What I tried
I want the Text objects ...
-1
votes
1
answer
43
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
%�...
-2
votes
0
answers
14
views
Stripe Connect Payouts API
I am creating an application in which users can add their bank accounts in the application and from admin side I want to send the payouts to their bank accounts. I am using Node.js and Stripe.js (In ...
0
votes
0
answers
3
views
Jest - react-native-color-matrix-image-filters/dist/CMIFColorMatrixImageFilterNativeComponent.js: Could not find component config for native component
I have a React Native Android project and I just upgraded the react-native version from 0.72.3 to 0.74.3. After a fair amount of library upgrading, TS and Lint fixes, etc I was able to get my ...
2
votes
3
answers
7k
views
How to change main content when sidebar item is clicked
Browsing stackoverflow, I see this as a very popular topic using various IDEs but none suitable to my needs.
I am working on a single page app (using: html, javascript, css) that has several files: ...
0
votes
1
answer
14
views
The input in searchbar disappears when i click on any other space/part of the browser of when i click tab button
import React, { useState, useEffect, useRef } from "react";
import { useNavigate } from "react-router-dom";
import axios from "axios";
import Autocomplete from "@mui/...
-1
votes
0
answers
2
views
req.headers.authorization is undefined
So I've been trying to implement JWT authorization for my project, and there's this specific step that I've been stuck for hours... So I have a middleware setup to try and verify the access token ...
-1
votes
0
answers
6
views
Create custom img collage from uploaded photos [closed]
is there some library to build custom collage, where user uploads img, and it will create collage?
Something like this. I dont really know where to start.
My idea is to create pre-defined grid, and to ...
-1
votes
0
answers
9
views
Combine arrays on update to Dynamo table - Cannot read properties of undefined (reading '0')
I have a DynamoDB table that is holding several pieces of data, of which one will be an array of objects.
I have a lambda that will handle another array of objects coming in that I am wanting to ...
0
votes
0
answers
24
views
How to use event.target.closest for navbar html javascript css?
I'm making a navbar. On click of items which has subnav pages, the navigation item/expands or collapses.
Here's the HTML/JS/CSS snippet.
const navHasChilds = document.getElementsByClassName("...
-3
votes
1
answer
40
views
How to trigger bootstrap toast ? other then button type="button", or fetch() [closed]
Is there a simple, other solution to trigger my boostrap toast which doesn't involve a button?
Maybe like :
button onclick ="trigger my bootstrap toast the easy way"
without the need of ...
0
votes
0
answers
27
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>
<...