Properly extending the DOM [closed]
I want to create a custom method that would be available inside each HTML DOM object. I achieved the desired result by prototyping the "Element" object, however, from what I've read this can lead to...
View ArticleTrying to press enter key in canvas every 1 seconds using a userscript
I am trying to create an userscript (to use with tampermonkey) which simulates pressing the Enter button every 1 seconds. I have tried // ==UserScript== // @name Userscript // @namespace...
View Articleform is not working for school project I must also get the answers into an...
the html seems to be fine from what I can see it's the javascript that is not working. I also need to get the answers into an array but that is a later problem that I can deal with. <form>...
View ArticleWhat does [{}].concat() in JS do?
I know this is something I could look up, but I have no idea what that's called much less what to search for. It'd be great to have a pointer!Some background, we're fetching an array of objects from an...
View ArticleHow to return an extended promise instance from an async function?
I'm just toying around with some ideas for my framework, lets say I extended the promise class like thisclass cool_promise extends Promise { cool_function() { console.log("I am cool"); } } and had an...
View ArticleHow to change the page url without reloading the page
I want to know how can I change the page URL without reloading the page or changing the page content. I already use that code (JavaScript):if(history.pushState){ window.history.pushState("object or...
View ArticleI encounter a problem when installing an npm module
here I start in javascript and nodejs / npm / webpack / theme-bootstrap, I encounter a problem when installing an npm module, I do not understand why ... I tried with various packages, so I say it must...
View ArticleESM importing all files from folder with index.js not working
Consider this very simple project: esm-testRuns on NodeJS 13.This project has "type":"module" in his package.json so Node will treat by default all files .js as ECMAScript Modules. See: ECMAScript...
View Articlejavascript: select Table column slide to another column for mobile view [closed]
Brief: In Mobile Screen Click on Column in Table 1 will Hide it and Slide to display a Column in Table 2 and I can Click on back button to return back to Column in Table 1 using javascript/jquery. How...
View ArticlePass files from input-element to plupload (Add folder)
I want to upload all files of a folder. Since plupload does not offer this functionality, I have an input like this<input type="file" name="files[]" id="files" multiple directory=""...
View ArticlePython Flask + HTML how to show selected parameters in URL
I have a python flask app and I'm wondering how to have the html page to show the selected parameters from dropdown list, text box, multi-selection etc.A toy example of my current-working setup looks...
View ArticleHow to filter/search columns in HTML table?
I have followed this link on how to create/filter search a table. But I want to filter search for each column in my own table. Currently, it only searches for the First Name column. How can I do...
View ArticleHow to call callback only when all functions done
I'm new to this asynchronous stuff. I learned how to use call back, but now I need to use two functions (Asynchronously) and only after they will finish I want to call my callback:function...
View ArticleIs there a Way to apply transition animation to a [Display : none;] property...
This question already has an answer here:Transitions on the CSS display property 32 answersI'm trying to apply animation to a div that is suppose to be displayed if someone hover over an image..like...
View ArticleJavascript object has no keys [duplicate]
This question already has an answer here:How do I return the response from an asynchronous call? 36 answersI am using React. I have an object (that I get from my props) which I was having trouble...
View ArticleWhat is console.log?
What is the use of console.log? Please explain how to use it in JavaScript, with a code example.
View ArticleHow to have two different text elements moving randomly on a page in Javascript
So I've been reading this post which I found is the closest to what I want. Basically, I want two different text elements (two different words) moving around the page randomly and also bouncing off...
View ArticleFullscreen to Maximize on MacOS using JS
I'm creating some custom MacOS 'Traffic Lights' for my React/Electron App. I've managed to get the Close and Minimize buttons to work perfectly fine, however, my Maximize (green) button will go...
View Articleonnx.js : Cannot read property 'webgl' of undefined
I tried the onnx.js (Getting Started example) from their git repository and it worked as expected.Now I'm trying the same thing with node.js and webpack, but I'm getting a weird error when loading the...
View Articlepassing from an input data as an array of images to the api
I am trying to pass from an input multiply images to the api as the following: <el-form-item label="images" prop="images"> <el-input name="files" type="file" multiple="multiple"...
View Article