web-component Questions
1
Solved
Is it possible to position nested shadow DOMs on top of each other?
With normal DOM, nested divs just stack by default:
.d1 {
width: 150px;
height: 150px;
background-color: lightseagreen;
}
...
Dalt asked 12/10, 2022 at 15:58
4
Solved
We have this custom element defined like so...
<my-button>
Submit
</my-button>
and the standard customElements definitions
class MyButton extends HTMLElement{
constructor(){
supe...
Earnestineearnings asked 18/3, 2019 at 6:4
1
Solved
Note: Existing questions exists here and elsewhere but they are all jQuery specific and there is no canonical answer covering plain JavaScript, including support for web components.
I'd like to sim...
Hessney asked 30/9, 2022 at 11:2
4
Solved
I'm writing a custom web component that is meant to be interactive. How can I tell the browser that this custom component should receive focus?
I wish that my custom element…
could be focused (b...
Mceachern asked 5/9, 2015 at 20:7
1
I'm very new to Lit and Web Components. I hope you can help me.
I wrote the following Element:
import {html, LitElement, PropertyValues} from 'lit';
import {customElement, property} from 'lit/decor...
Suit asked 14/9, 2022 at 9:8
2
Solved
I want to test the content of a slot in one of my custom components.
If I use my component in an html-file and open it in an browser, everything works as intended. However if I want to automate my ...
Tater asked 25/9, 2021 at 15:20
4
I'm trying to use the font awsome js/svg library within a web component but the icon wont show. is this possible?
I'm trying to implement an angular component inside an existing webforms project w...
Anacreontic asked 4/5, 2020 at 7:33
6
Solved
What is a good way to apply styling dynamically (i.e. the value of styles are created at runtime) to HTML elements with JavaScript?
I'm looking for a way to package a JavaScript widget (JS, CSS an...
Chantress asked 25/2, 2016 at 14:51
1
Question has been updated
I'm trying to use a Pinia's store with web components created with Vue.js but I have this error in the console:
[Vue warn]: injection "Symbol(pinia)" not found ...
Picaroon asked 24/8, 2022 at 16:5
9
Solved
I am doing this Router tutorial.
My App.jsx file:
import React from 'react';
import ReactDOM from 'react-dom';
import { Router, Route, Link, browserHistory, IndexRoute } from 'react-router'
clas...
Meshwork asked 10/7, 2016 at 16:4
2
Solved
I would like to integrate web components into my react app. They define a set of custom events that the enclosing react app must listen to.
According to the react docs:
Events emitted by a Web ...
Peasant asked 30/3, 2020 at 9:1
2
Solved
When creating Web Components with encapsulated styles using Shadow DOM, parts of the shadowed markup can be styled using the ::part pseudo selector (https://developer.mozilla.org/en-US/docs/Web/CSS...
Tennyson asked 9/2, 2022 at 10:14
2
Solved
Is it possible to automatically or programmatically slot nested web components or elements of a specific type without having to specify the slot attribute on them?
Consider some structure like this...
Anallise asked 23/12, 2020 at 10:53
7
I have created an Angular Web Component like below
@Component({
selector: 'dlx-slider',
templateUrl: './slider.component.html',
styleUrls: ['./slider.component.scss'],
encapsulation: ViewEncaps...
Ambala asked 13/10, 2018 at 22:20
2
I'm making an embeddable widget for websites using Vue.js and vue-custom-element. Everything was going smoothly until I ran into a problem.
When I'm trying to use a component (with css) from a pack...
Flinch asked 26/1, 2021 at 15:13
1
I'm facing some issues when rendering a React component into the shadow DOM of a webcomponent.
I wrote a small piece of code to turn a React component into a webcomponent, but I want to render the...
Haematozoon asked 24/11, 2014 at 9:6
3
Solved
I need to basically pass a value down to my web component, I will then do some random thing to it, now I want to pass that new value back up to my React Comnponent. How do I do that?
function MyRea...
Celiotomy asked 21/5, 2022 at 0:15
7
I'm using Web Components v1.
Suppose two Custom Elements:
parent-element.html
<template id="parent-element">
<child-element></child-element>
</template>
child-element....
Crimmer asked 7/2, 2018 at 12:21
2
I want to start leveraging http://webcomponents.me W3C standard which is now supported by all major web browsers.
I researched the internet and so far I found following frameworks:
Stencil - Cre...
Inigo asked 19/3, 2019 at 20:3
3
I would like to create a library of web components using Angular Elements that have default templates but allow developers to override the output.
For example, consider a search-results component. ...
Lawler asked 10/4, 2022 at 18:34
3
Solved
I have a created a small web component with the help of this article using angular element which includes @Input and @Output.
I am able to pass data to @Input property but listening to the @Output...
Bloomery asked 4/11, 2019 at 6:54
1
Solved
I want to use few web components from https://github.com/microsoft/vscode-webview-ui-toolkit. But I don't know to how to use them in Svelte as svelte treats the web components as svelte components....
Echeverria asked 1/3, 2022 at 5:44
4
Solved
I'm exploring imports, templates, shadow DOM and custom elements in Chrome Canary (33.0.1712.3). In a grid layout I have a particular content element (region of the display) that will display diffe...
Levin asked 20/11, 2013 at 7:39
1
Solved
I am creating a web-component using VueJS 3, I want to expose a method on the component allowing the user to do something like this:
<custom-component id="x1" />
<script>
...
Gape asked 20/2, 2022 at 19:56
1
Solved
I'm building a website with using only native, vanilla JS features (ES6, web components, import modules).
I'd like to include a polyfill to get Safari to support extending HTML elements (class MyLi...
Talkie asked 10/5, 2021 at 7:44
© 2022 - 2024 — McMap. All rights reserved.