Questions tagged [dom-element]
11 questions
18
votes
2 answers
Converting an ElementHandle to a DOM element using puppeteer?
This is how I currently get each DOM property from an ElementHandle :
let section: ElementHandle = await page.waitForSelector(".selector-list li");
let tagName = await section.$eval('a', (e) => e.tagName);
But here it's tagName. What if I'd like…

Royi Namir
- 144,742
- 138
- 468
- 792
3
votes
1 answer
HTML DOM id Array Property & Adding to Stage JavaScript (Array)
I am trying to create an array of values using a for loop in JavaScript with multiple div id's with successive numbers (i.e. their values) denoting depth. The issue that I am running into is that I can't add the DOM element, i.e. 'text by ship here'…

William Garske
- 317
- 1
- 10
2
votes
1 answer
styled component error "it looks like an unknown prop "responsive" is sent through to the DOM, which will likely trigger a React console error."
I am using react data table component which requires me to install styled component.
The moment i render the DataTable after passing the columns and data prop, I get various errors on my console saying there is a problem with some of the props im…
2
votes
1 answer
Element.scroll[To]() doesn't work as expected in a userscript
I'm the creator of JANITOR – Java API Navigation Is The Only Rescue which:
Inserts a navigation tree [...] into [...] pages [...].
I lazy-load the content of a branch when it is clicked to open it and the idea is to scroll the selected item to…

Gerold Broser
- 14,080
- 5
- 48
- 107
1
vote
2 answers
CYPRESS- error during type a value from API request to input
When I try to type OTP code (I get it from API), cypress shows an error cypress screenshot
cy.get('input[data-placeholder="OTP"]').type(getOtpCode(phoneNumber))
function getOtpCode(phone) {
var otpCode;
cy.request({
method: 'GET',
…

Marcin
- 97
- 7
0
votes
0 answers
IFrame get scroll position
I am scrolling a pdf file inside an Iframe and trying to access the scroll position but failed to do so. tried all the resources but they don't seem to work anymore. Any help is Greatly Appreciated.
const iframe =…

Mayank
- 1
0
votes
0 answers
HTML emulate the concept of c#s Flags Enum
On my html form I want to emulate the idea of a Flags Enum, for example
[Flags]
public enum ColorChannel {
None = 0,
Red = 1,
Green = 2,
Blue = 4,
Alpha = 8,
All = 15
}
Cases:
None => All other options should be deselected.
Any Channel(s)…
user3915050
0
votes
2 answers
GTM variable DOM element image URL
I added dynamic structured data for recipes to my webiste, but the variable for the recipe image is not displayed correctly. The data layer autmatically adds two backslashes in front of every slash of the url. This causes problems with the rich…
0
votes
1 answer
Why are React components executed through the `React.createElement()` method?
Given that a React component is essentially a function:
const Component = ([props]) => React.createElement(type[, props [, ...children]]);
when I try to call it as any normal function:
Component([props]);
it doesn't work.
Meanwhile, in the React…

jurgen_gjoncari
- 65
- 8
0
votes
1 answer
The Unordered List Data getting destroyed when another dom element is getting clicked? The page is built in aspx
I am trying to display the the data in an Unordered list which is coming from an API. Below is the code how I have implemented it. Its working completely fine and the data gets displayed as well. But as soon as someone clicks on any other buttons…

Ajay Kushwaha
- 80
- 1
- 10
-1
votes
0 answers
Creating attribute only xmlns in Mozilla
I am trying to create attribute only xmlns. Browsing in Chrome does it without problems, but Browsing in FireFox creates xmlns:xsi.
If I change the name of the attribute, it will add it reliably, but the clean xmlns one will definitely not. I tried…

Gabriel Gajdoš
- 1
- 2