Skip to content

bug: defineCustomElements return type is wrong #4589

@andrew9994

Description

@andrew9994

Prerequisites

Stencil Version

4.0.1

Current Behavior

Currently the return type of defineCustomElements is defined as a Promise<void> on this line in the output-lazy-loader,
but the promise got removed in this commit.

Expected Behavior

The return value of defineCustomElements should be typed correctly. However, I am not sure whether this change should be marked as a breaking change.

System Info

No response

Steps to Reproduce

Import defineCustomElements from the loader of a package and try to do something after the promise gets resolved.

import { defineCustomElements } from 'stencil-package/loader';

defineCustomElements().then(() => {
  console.log('elements defined');
})

Code Reproduction URL

n/a

Additional Information

No response

Metadata

Metadata

Labels

Bug: ValidatedThis PR or Issue is verified to be a bug within Stencil

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions