-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Closed
Description
Description
If you do navigation preloading or similar you may already have the data for the task at component creation time. Then it would make sense to be able to either set that data manually at Task creation time or using some attributes.
The simplest but probably also most unclean change would be to make _value
lit/packages/labs/task/src/task.ts
Line 108 in 57a53e1
| private _value?: R; |
public and name it value
Steps to Reproduce
import {Task} from '@lit-labs/task';
this._apiTask = new Task(
this,
taskFunction,
() => /** @type {[URLSearchParams]} */ ([this.history.url.searchParams])
);
if (this.initial !== undefined) {
this._apiTask.status = TaskStatus.COMPLETE;
// TODO FIXME don't use this private attribute that got minified
this._apiTask.P = this.initial;
}Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Status
✅ Done