InternalsAttached

The InternalsAttached mixin provides access to Element Internals API through the internals symbol.

Usage

Elements that mix InternalsAttached get access to ElementInternals via the internals symbol:

import { InternalsAttached, internals } from './mixins/internals-attached.js';

class MyElement extends InternalsAttached(LitElement) {
  constructor() {
    super();
    this[internals].role = 'button';
  }
}

Properties

NameTypeDescription
[internals]ElementInternalsAccess to the element's internals via the internals symbol. Automatically created on first access.

Notes