问题
I am trying to integrate the web component built using StencilJS but I get the following error.
Uncaught (in promise) TypeError: Cannot read property 'isProxied' of undefined
at initializeComponent
ReactJS, index.js file =>
import {defineCustomElements} from 'my-modal/loader';
defineCustomElements(window);
StencilJS component:
import { Component, Prop, h } from '@stencil/core';
@Component({
tag: 'my-component',
styleUrl: 'my-component.css',
shadow: true
})
export class MyComponent {
@Prop() first: string;
render() {
return <div>Hello, World! I'm {this.first} <hr />
</div>;
}
}
Any thoughts ? :)
来源:https://stackoverflow.com/questions/58078580/unable-to-integrate-stenciljs-component-in-react-application