Replies: 1 comment
-
|
There has been discussion around creating constants or enums that can be used instead of a type-literal, can't look that issue up right now. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
What is the intended way of
wxtto link to a HTML page (just like as a normal HTML page, but shown/run in your browser)? E.g. one could re-use the existing HTML inentrypoints/popup/index.htmlor so depending on what is intended to be shown.Context
I am building a little website. Coming from that initial website that is basically just storing data I thought we need to store/sync data and thus "converted" it into a WebExtension for data storage via
browser.storage.sync(or similar APIs).Anyway, the more generic question is: If you have to link to a HTML (or, for whatever matter, to some other asset like an image or whatever), how to best open it in a wxt-compiled extension/code?
Use cases
Examples for why you would want this:
Concrete example/code
Intuitively, me (and LLMs 🙃) would write this (given the default project structure) for the popup example:
However, apparently correct (after the build steps, as far as I saw in all build variants) would be:
Finding this really left me puzzling and I also see
no docs mentioning this(Edit: Ah now I see, it's the "Output Path" in the docs, 😲 - this was not obvious IMHO) or having this in mind.Problem
Now, the "solution" above still is problematic. It is like "guessing" a path, it's not included in the build, thus:
So is there any better way?
Preliminary suggestions
If there is no existing way, ideas for improvement would be:
Beta Was this translation helpful? Give feedback.
All reactions