Category "javascript"

unable to show error and error message on MUI datepicker

I'm using react material-ui (MUI) I want to show an error on some condition that will calculate on the backend. I used MUI-datepicker but I can't show error imp

How to handle nested frames from content script to background script?

I am creating a webextension for Firefox, aiming to collect data in a browser game. I've started with a simple test to manage injections and communication (with

Responsive nav bar not sticking on some screens

I am having a problem with the taskbar on my webpage. It is "sticky" on scroll down on a laptop screen, even when I resize the window to a size where the nav me

How do I change slate editor value using Javascript (DOM manipulation)

I want to change the text in the slate editor using DOM manipulation via Javascript. Dynamically change the values filled into editable components in a particul

react-router-dom router change the url but nothing else. All of components are not changed

I can't solve why it doesn't work. When I clck on the link new page the url is changing but the page not (it should change to new page with div witch some conte

How to create fixed scrolling in Locomotive Scroll in Next.js

I'm currently using Locomotive Scroll with NextJS to implement smooth scrolling. The web app that I'm currently developing with NextJS requires a fixed scrollin

How to make useEffect listening to any change in localStorage?

I am trying to have my React app getting the todos array of objects from the localStorage and give it to setTodos. To do that I need to have a useEffect that li

Javascript: How would you get the highest rated product category based on these 2 arrays

Assuming I have 2 arrays: const products = [ { name: 'prod1', category: 'Meat' }, { name: 'prod2', category: 'Meat' }, { name: 'pr

JavaScript event.preventDefault() submit button data in _POST

There is something I can not seem to find documentation on: I have this form with multiple buttons. The buttons have their own actions associated with them and

Set larger width than 500px of tooltip in extjs grid cell

i have a grid cell with a very very large text inside. I want a tooltip which shows the whole text, but the tooltip is everytime only 500px large and cuts the t

Text input field won't submit when pressing enter

I have a text input that I am trying to use to create new tags via hooks. However, when I enter in the value and press enter, nothing happens. I Googled it and

post request using crud crud in react js

Trying post request in crud crud dynamically using fetch api but its showing error net::ERR_ABORTED 415 (Unsupported Media Type) const addItemToCartHandler = as

How to pass a function from Parent to an element within a route in React.js?

I want to pass a function to a component through a Route , I can do it with direct children but when it comes to Routes i can't figure it how to do it. look at

How to use local storage in my TODO list js

I'm trying to solve a task in javascript, I'm learning but don't now how to use the local storage, or how to use it in my todo list, I can add task, mark them a

next-images Error: Module parse failed: Unexpected character '�'

I'm trying to load an image with next-images: when i type in the image name it works fine: //Working <Image src={require(`../../images/exampleImage.jpg` )}/&

How to hide buttons based on your "job"?

I am creating an app and I want that the buttons appear based on your $job. There are 4 jobs, which are all in mysql databases: student teacher staff principal,

Produce CSV from JSON object

I have a JSON Object like so that I am trying to produce a CSV from { "football": { "count": 2109, "emailed": 0, "optin": 2109,

Html ReferenceError: document is not defined

My error = ReferenceError: document is not defined document.getElementsByClassName("text_status").innerHTML = 'hello' I am trying to change the text of an elem

Deploy different from view on local server

I was building a site and during building I checked it out through live server and everything was OK. Now after deploying on netlify. The site looks different a

I am having trouble understanding the Leader-Line js documentation

I am trying to create code that will draw a line from point a to point b using the leaderline library. https://github.com/anseki/leader-line It looks like the s