Category "javascript"

How to pass a javascript (js) Map to spring boot Controller?

I've a Java Script map having key value pairs which i Need to send to spring boot contoller :-- Example :-- var myMap = new Map(); myMap.set('1',

Karma Chrome Headless not working on Jenkins

When I run the below setup with Docker locally on my mac everything works fine. But same setup does not work on Jenkins running on Ubuntu 16.04 ChromiumHeadle

How to know when all Promises are Resolved in a dynamic "iterable" parameter?

My problem is that I don't know how to know when a dynamic promise array has all the promises resolved. Here an example: var promiseArray = []; promiseArray.p

Can't import global package in Node even though NODE_PATH is set?

I'm trying to import a globally installed pkg located at /some/path. I have set NODE_PATH in ~/.bash_profile. I am able to do 'echo $NODE_PATH' and see my path

How to enabling Tool tips or my react library?

My Project: A React JS library (Not Typescript) created with create-react-library. The library works as expected. My Question: How do I get the tooltips/hints

protractor, on login form sendkeys() are not working. Browser don't displays my value for the form fields

(I'm not using jQuery) Hi! I'm starting with protractor and cucumber and i'm testing a login page. I'm trying to insert values on a form for the login, but when

I want to generate page as a single pdf file without page break

Hi i want to generate a pdf of big page as one single file without page break. Below image shows page break upon download(that i want to avoid

How to get user's photo(profile) using Microsoft Graph API?

When a GET(https://graph.microsoft.com/v1.0/users/ {{user_id}} /photo/$value) request is made, the response data will be written with the same characters as ima

aws cloud9 lambda import failed

I have a working production environment with several Lambda deployed from my PC using AWS SAM. I want to transition my lambda to Cloud9 and debug from there b

How to add icon of the app on the home android screen (react-native)?

When installing on Android, it does not add a shortcut on home screen, but the app used to. You can find it in the app drawer only now. How to add icon of the a

Add an input box for each dropped file in dropzone

I have a drag drop box with dropzone.js. I allow multiple files upload (max 5 files at present). I have asked to add an ability for user to add description for

Multiple UVs/textures for single mesh in THREE.js

I have an OBJ that uses four textures. The UVs defined in the file range from (0, 0) to (2, 2), such that (0.5, 0.5) refers to a coordinate in the first textur

'http://127.0.0.1:5500' has been blocked by CORS policy

this is index.html code <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta http-equiv="X-UA-Compatible"

How to retrieve all posts of a user via Facebook Graph API using promises and recursion?

I am currently developing a web app which uses the Facebook Graph API. What I would like to achieve is to get all posts of a user. However, this is not that e

How to use Stripe's secret key and publishable key?

I would like to connect with the Stripe API using a https call using the https library. var https = require('https'); I have gotten the secret key and publis

Dynamically-added Parameter to JS File (cache-busting) Does Not Cause Reload

I've added a random date param to my CSS and JS files in order to "cache-bust"... HTML (head) <!-- STYLE --> <link href="assets/css/style.css" rel="s

Shrinking sticky sticky header causes flicker in Blink/Webkit at certain scroll positions

I have a sticky header which utilizes IntersectionObserver to gain a class when stuck, which then hides a few elements and reduces the size of the logo. Of cour

Pattern for Firebase onAuthStateChanged and Navigation Guards - Quasar app

I am facing an issue in my Quasar app with regards to browser refresh and Firebase authentication. After a user logs in and then clicks on the browser refresh,

Object.create({}): Is is a good practice?

I've been talking to some professionals who work with JavaScript in a company, and I've been told that it isn't a good practice to create an object instance usi

Why wont my if statements work in cypress?

I'm trying to write a test that goes back in a calendar to look for a specific date to click. I have come up with an IF statement that should loop to the next m