Skip to content

Comments

feat: redesign preload APIs#45230

Merged
samuelmaddock merged 8 commits intomainfrom
feat/redesign-preloads
Jan 24, 2025
Merged

feat: redesign preload APIs#45230
samuelmaddock merged 8 commits intomainfrom
feat/redesign-preloads

Conversation

@samuelmaddock
Copy link
Member

@samuelmaddock samuelmaddock commented Jan 16, 2025

Description of Change

Split from #44411
Implements part of RFC #8

Preload scripts now require options beyond only their script location. The type property supports 'frame' with planned support for 'service-worker'.

Given the requirements change, I took this opportunity to make our preload APIs better support third-party libraries based on our best practices.

Checklist

Release Notes

Notes:

  • Redesigned preload script APIs by introducing registerPreloadScript, unregisterPreloadScript, getPreloadScripts on Session.
  • Deprecated getPreloads and setPreloads on Session.

@samuelmaddock samuelmaddock added semver/minor backwards-compatible functionality target/35-x-y PR should also be added to the "35-x-y" branch. labels Jan 16, 2025
@samuelmaddock samuelmaddock requested review from a team as code owners January 16, 2025 20:46
@samuelmaddock samuelmaddock added the api-review/skip-delay ⏰ Skip the mandatory 7 day waiting period for new APIs label Jan 16, 2025
Copy link
Member

@codebytere codebytere left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

API LGTM

@codebytere
Copy link
Member

@itsananderson it looks like the skip-delay might not be working as expected:

Screenshot 2025-01-17 at 10 55 55 AM

@samuelmaddock samuelmaddock added api-review/skip-delay ⏰ Skip the mandatory 7 day waiting period for new APIs and removed api-review/skip-delay ⏰ Skip the mandatory 7 day waiting period for new APIs labels Jan 17, 2025
@itsananderson
Copy link
Member

It's not clear to me why Cation isn't applying the Skip Delay logic. I've opened electron/cation#179 to add more logging to the code that handles that label.

Copy link
Member

@itsananderson itsananderson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

API LGTM

@samuelmaddock samuelmaddock added api-review/skip-delay ⏰ Skip the mandatory 7 day waiting period for new APIs and removed api-review/skip-delay ⏰ Skip the mandatory 7 day waiting period for new APIs new-pr 🌱 PR opened recently labels Jan 23, 2025
@electron-cation electron-cation bot added new-pr 🌱 PR opened recently and removed new-pr 🌱 PR opened recently api-review/requested 🗳 labels Jan 23, 2025
@samuelmaddock samuelmaddock merged commit e09577b into main Jan 24, 2025
66 checks passed
@samuelmaddock samuelmaddock deleted the feat/redesign-preloads branch January 24, 2025 02:12
@release-clerk
Copy link

release-clerk bot commented Jan 24, 2025

Release Notes Persisted

  • Redesigned preload script APIs by introducing registerPreloadScript, unregisterPreloadScript, getPreloadScripts on Session.
  • Deprecated getPreloads and setPreloads on Session.

@trop trop bot mentioned this pull request Jan 24, 2025
@trop
Copy link
Contributor

trop bot commented Jan 24, 2025

I have automatically backported this PR to "35-x-y", please check out #45329

@trop trop bot added in-flight/35-x-y and removed target/35-x-y PR should also be added to the "35-x-y" branch. labels Jan 24, 2025
@trop trop bot added merged/35-x-y PR was merged to the "35-x-y" branch. and removed in-flight/35-x-y labels Jan 31, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api-review/approved ✅ api-review/skip-delay ⏰ Skip the mandatory 7 day waiting period for new APIs merged/35-x-y PR was merged to the "35-x-y" branch. semver/minor backwards-compatible functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants