Category "javascript"

How to include a string in my website url?

I created a shop and the url is like:https://myshop.com But my client asked me to add respective salers' id into the url so that they can do some analyses, so i

How to make exe files from a node.js app?

I have a node app that I wrote, that I run as follows: node.exe app.js inputArg Is there some way I can package this into a .exe by itself? So I can just do s

warning after login .how to solve this error?

Cannot update a component (BrowserRouter) while rendering a different component (Login). To locate the bad setState() call inside Login, follow the stack trace

Multiple forms with one submit() method by Vue

I have a few forms. Every of them have the same logic (validation, sending...) so, I want to create one method to control actions on my forms. For now my code i

React UseEffect is being calling twice

I have the following code in FC component: I just want to call the Api and Log the info when the component is mounted The console.log is being called twice fo

subtle crypto with ECDSA : Cannot create a key using the specified key usages

I wanted to import an ECDSA private key in Chrome to sign some data, tried yet with crypto.subtle.importKey: feeded the importKey with a derivated private key u

JQ validation error appear on select value change

The form required the user to input phone number if its not employee, I have done this part. How to make the validation error appear on select value change? For

What is <router-view :key="$route.fullPath">?

I'm completely new to Vue.js and I think I have a bit of understanding of how a router works with things like: <router-link to="/"> But I am not really u

Image in React component loading on one page but not the other one?

Hi guys very simple question. I have a home page and a room page. The question is why is the logo image in the navbar component loading in the homepage but not

Event binding on dynamically created elements?

I have a bit of code where I am looping through all the select boxes on a page and binding a .hover event to them to do a bit of twiddling wit

Laravel Livewire: jQuery not working in child component loaded via @if statement

I'm using Laravel 8 and PHP 8 and livewire 2. I have a Fullpage Livewire component. I have a button, to toggle a simple flag between false and true. <Button

React i18next not working on Firefox/Microsoft Edge browser?

I am using React i18next library for localization in my application. Everything works fine when using the library on localhost, but when I produce a production

Synchronized API request and writing to files

I'm working on a node.js application that, once each week, will make a series of API fetch requests, and store the returned JSON into files. Currently, the code

prop passed to child component not updated after async call

I am new to React and building a movie db app. I have defined my async fetch movies api call in API.js and call this in the Home.js components' useEffect and se

Is it is possible to test only one function from component with Jest?

I have react component, for example something like this: const MyComponent = (props) => { const [state, setState] = useState(true); const {data} = useCon

Get last modified page

How do I get page number, which is modified (deleting/adding content) in Google doc, Google Slide in last modification time? I have used Google drive revision

Queryselectall for selecting invalid input types

For simplicity sake, I have the following html that I didn't write and I have no control over. <input type="text" id="532523" name="safgafg"> <input t

Use Quasar App code in background script of BEX

I am developing a browser extension using Quasar framework's BEX mode. In the app part (popup window), I have a TypeScript file which contains some common funct

Bootstrap validation in a dual-purpose form not working

I have a form that is used for both Adding and Editing an Organisation. If the form is in Add mode (default) then you also create a default Admin user as part o

jQuery .load() run the same as body displayed

i have a project that needs to include external html to my page. so this file will be included to many page. I'm using jQuery here. Let me show some code: $(doc