Quantcast
Channel: Active questions tagged javascript - Stack Overflow
Browsing all 138134 articles
Browse latest View live
↧

How to call a function once from Obserable.subscribe regardless if there are...

There is a observable that takes data from endpoint:this.get().pipe( filter(item => item.id = providedId) ).subscribe((data) => { specialFunction(data); }) When the filter method of RxJS finds an...

View Article


display text instead of icon on mouseover - React material ui button

I am using material ui button in my project. Initially the add button is having only + icon. When the mouse is hovered I need to change the content of button from the icon to the text "CREATE ITEM"The...

View Article


checking text appears inside an element using react testing library

I'm writing some tests for a React app using Testing Library. I want to check that some text appears, but i need to check it appears in a particular place because I know it already appears somewhere...

View Article

Do HTML elements have 'hidden indexes' for the DOM?

For example, document.getElementsByClassName("whatever") returns a list of elements, and each element has an index (so the element x is the [3] in that list, for example).Do HTML elements save that...

View Article

SyntaxError: Cannot use import statement outside a module

I've got an ApolloServer project that's giving me trouble, so I thought I might update it and ran into issues when using the latest Babel. My "index.js" is:require('dotenv').config() import...

View Article


Mongoose schema method and .pre('save') not working

I can't understand why the schema.method.log and schema.pre('save') doesn't work.I appreciate any help!// plugin.js const LogSchema = require('../models/log') const plugin = function (schema) {...

View Article

I can't unsubscribe firebase firestore react native

I am using firebase firestore in an application with react native. The fact is that I have tried all the unsubscribe forms of the onSnapshot listening events without success and I get an error when...

View Article

How to determine with vanilla javascript that a is scrollable?

This question is inaccurately answered here (Detect if the DIV have scroll bar or not [duplicate]) and in other questions on SO.The answers don't take into account that the content of the div may have...

View Article


display data in different divs

I would like to wrap all the text that I'm retrieving from an api in one div and the image that I'm retrieving in a different div so all the data is still printing but they are in separate divs? How...

View Article


How to launch XSS code into an HTML input field?

im working on trying to find vulnerabilities on a fake website for class and I was wondering how to launch XSS code into this input field?This is the code from the website:<form name="friendForm"...

View Article

Show hide content based on check boxes, if one check box checked disable...

I have three check boxes, first one will be checked by default and content will display, corresponding to first check box.if I checked second checked box, first check box will unchecked and content...

View Article

What are the differences between javascript export syntaxes?

I'm trying to understand if there are any differences between the ways to export a component in javascript. I understand how a default export works, and how to export variables, like:// when exporting...

View Article

Why am I getting the word undefined when I run changeword.js?

So , I was trying to make for my website an automatic way that the words can change, It almost worked , but idk why I get the word "undefined"; Can you please...

View Article


Bootstrap v3.3.0 - Update Multiple Select checkbox with JQuery :...

I have a drop down multi-checkbox selection, sample below:<div class="form-group"> <label class="col-md-3 control-label">PG</label> <div class="col-md-9"> <select...

View Article

Jest how to make sure I get back a string value?

I have a test that returns a token. I can not match the token because i get back a unique token ever time. I am looking for a method/way to make sure I always get back a stiring.code so...

View Article


Can i use Webpack HMR without webpack-dev-server or webpack-dev-middleware?

Is it possible to set webpack 4 configuration to use webpack.HotModuleReplacementPlugin() without any server side functional?In this case client script in browser, for example, should check for...

View Article

Stuck on PHP JavaScript interaction

ive been working on this code for a while now and have been stuck several times but this time around I think Im stuck for real.I'm not a coder, I just enjoy it as a hobby so dont get to frustrated over...

View Article


Forms Data Submit

my button is not working for register execute page. html code<form> <h3>Let`s Get Started</h3> <br /> <span id='message'></span> <br /> <br /> <label...

View Article

Image may be NSFW.
Clik here to view.

how to store foreach return value in array and send two response in express?

I tried to store the doctor details in array and display appointment and doctor Name Value response. Appointment value is acheived but doctor Name Value comes empty even if it shows in console.// get...

View Article

Problem Logging a PHP Variable in Javascript

Am working on an application whereby am passing a PHP array from the backend to Javascript frontend. Am trying to log he variable inside Javascript when the page loads so that I can dissect the array...

View Article
Browsing all 138134 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>