Skip to content

Comments

Main/Preload Restructure#741

Open
yofukashino wants to merge 19 commits intoreplugged-org:mainfrom
yofukashino:main-structure
Open

Main/Preload Restructure#741
yofukashino wants to merge 19 commits intoreplugged-org:mainfrom
yofukashino:main-structure

Conversation

@yofukashino
Copy link
Contributor

Change the Main and preload file structure for ease of expansion.

New Structure goes as the following:

  • /preload.ts (Removed since made into a folder)

  • /preload/index.ts (preload loading)

  • /preload/RepluggedNative.ts (Moved RepluggedNative Object and type into this)

  • /main/index.ts (Removed Everything Replugged Related)

  • /main/replugged.ts (Everything Related to replugged gets loaded/imported here)

  • /main/csp.ts (Moved CSP into its own file so that we can whitelist stuff in future easily)

  • /main/patches/* (AppSettings, BrowserWindow, ProtocolScheme or anything goes into its own patch file and gets loaded in replugged.ts. Export patches in /main/patches/index.ts)

  • /main/patches/on-ready/* (permission handler or any patch file and to get loaded after app is ready. Export patches in /main/patches/on-ready/index.ts)

@yofukashino yofukashino changed the title Main structure Main/Preload Restructure Sep 5, 2025
@yofukashino
Copy link
Contributor Author

Quick question:
Which is better, /main/patches/on-ready/csp.ts or /main/csp.ts?
I mean, is it supposed to be a patch?

@fedeericodl fedeericodl added refactor semver: none This is an internal change and doesn't affect anything in the release labels Sep 14, 2025
@yofukashino yofukashino mentioned this pull request Sep 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

refactor semver: none This is an internal change and doesn't affect anything in the release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants