Are you migrating one element at a time, or a whole app?
The best way to do style sharing with LitElement is to use static styles:
share-styles.js:
export const sharedStyles = css`
h1 { color: blue; }
`;
element.js:
import {sharedStyles} from './shared-styles.js';
export class MyElement extends LitElement {
static get styles() {
return [sharedStyles, css`
:host {
display: inline-flex;
}
`];
}
}
If you're migrating incrementally and need to use Polymer shared styles, I
think you'll need to use the DomModule class to find the style sheet. I can
look up some code for you if this is the case.
On Thu, Jun 20, 2019 at 9:17 AM Suvarnnan Vasudev <
suvarnnanvasu...@gmail.com> wrote:
> Hi,
> I have following code snippet in polymer .This code uses
> shared-styles .This internally has implementation as below .
>
>Polymer element
>
> *class SHButton extends PolymerElement {*
>
> * static get template() {*
>
> *return html`*
>
> **
>
> *