Category "javascript"

MarkLogic server-side JavaScript and XQuery

I am just starting using NoSQL MarkLogic DB and trying to choose for me the best query language to learn and use in future. On server side MarkLogic provides th

how to move Javascript created DIV to bottom of page

I have swagger ui HTML page. there is generating HTML tags and divs with javascript so I want to move this whole description div to the bottom of the page. but

Deploying Solana Metaplex contracts for further extending

Helloy guys, does smb know, how to deploy metaplex smart-contracts separately from this repo??? Did smb tried it? https://github.com/metaplex-foundation/metaple

Node JS file write time [duplicate]

I have code that writes data to a file, how can it be done to show how much time it took to write a file? const fs = require("fs"); fs.writeFi

Vue 2 Reactivity: computed property doesn't trigger DOM update [closed]

I have a computed property based on some nested object properties. When the object gets changed, the computed property seems to update (In vu

Mapbox Javascript markers with elevation/altitude in Javascript

By default, Mapbox markers are set to ground altitude. Is there some way to elevate their position? It is to represent some drones position, elevated over the m

How can I measure the actual framerate of video using JavaScript?

Assume a video is playing in an HTML5 page using the <video> tag. How can I measure the actual framerate? I do not just want to read the framerate of the

Significance of ';' after for loop condition in JS

const arr = [] for(let i=0 ; i<=5 ; i++ );{ arr.push(i) } console.log(arr) Can anyone explain me this scenario ?

I need help understanding a Javascript function used to search a list with a search bar so I can modify it to search a table

I'm working on a college assignment where I use a PHP class to generate table values which a Javascript function then searches with a search bar. It builds off

use response data in columndef datatable jquery

I am using datatable jquery.I want to use Sr_no in data-id of td tag but How to get data of Sr_no. or you can say that I want particular data from data reponse

How to add key and values to anobject by splitting a string inside the object

I have the following array: [ { “Key”: “CUST”, “Segment”: “A;B;C;D;E” } ] I want to transform it to

nextjs router locale undefined

I have done a lot of research and tried many things, but unfortunately, I haven't found a solution, so I had to ask again. I am working locally on a project and

Date.getTime is not a constructor [duplicate]

In a function I have the line: const currentTime = new Date.getTime(); The code compiles just fine. Also, ESLint displays neither warnings or

HTML/CSS that worked in chrome looks all mangled up in firefox

So I am trying to create this success modal box which looks absolutely fine in Google Chrome but completely breaks in Firefox. Can I please get some help with w

Creating Sticky Navbar with Drop Down Menu HTML

I am creating a HTML web page which contains a sticky navbar with drop down menu. However, when I created one, the dropdown menu does not works in the sticky na

How to order comments in firebase firestore by createdAt

I have a document in which there is a comments array of objects and each object has createdAt property. I want to sort all the comments that are inside the comm

Chartjs tooltip and draw line separatly

Chartjs 3.6.1; typescript 4.3.5 I would like to draw a vertical line on chartJs, where the user clicked (once). I can draw a line in the chart.options.onClick()

Javascript: Change element class if button has a certain value [closed]

<div class="main-div main-div2"> <!-- IF up to date, main-div3 --> <button id="update-btn" class="btn update

Expanding Text Area throws error on Chrome/Firefox but not Safari

I have a text area that dynamically expands to fit the content inputed. It works correctly on all browsers, as far as I can tell, but on FireFox and Chrome it g

Trim mobile numbers in textarea field

I have a textarea field in a form where I can copy paste (or type) mobile numbers. It will have one number per line, like this I can copy paste (or type) thousa