React Devtools
Has anyone had any success using the react devtools in the new tab page? The redux one works but not the react one for some reason. I went to the chrome extension settings and gave it permissions to access file URLs but that didnt help
chrome.identity is undefined
I'm trying to do ...
chrome.identity.getRedirectURL
but getting the following error
Uncaught TypeError: Cannot read properties of undefined (reading 'getRedirectURL')
Uncaught TypeError: Cannot read properties of undefined (reading 'getRedirectURL')
Project won't re-package
I have projects A and B
When I
pnpm dev --verbose
in B, it works fine
When I pnpm dev --verbose
in A, it's stuck on
```
🟡 16 | Starting dev server on 1012, HMR on 1815......Live reloading Discussion
Bug, discuss, implementation detail, how to improve Live reloading in Plasmo
Creating tests for CSUI React components with Jest
Heyo. I've been toying with the jest example in order to implement tests in an extension, but the lack of documentation and complexity of the example is giving me a lot of headaches getting everything working.
The example doesn't deal with any imports in the example component, neither from static files, style files, parcel bundler imports, etc... So it makes it quite hard to figure out how to make it work with components that have any of them. Jest will complain to no end about it.
Also, I'd rather deal with a different folder structure than having every test isolated in a single directory. I'd rather have each test stay with their respective tsx and scss component files, but the example configuration is quite obtuse as how it parses the test files (does it just look for the .test.ts(x) extension regardless of the location?)...
Mantine modals not rendering + styles are broken
I'm using a modal with https://mantine.dev/ but it's not rendering on the screen. When I inspect the modal, I'm only then able to see it on the bottom of the page and the mantine styles are not being applied to it
using getInlineAnchorList with Mantine
I'm trying to inject a Mantine button into multiple components at the same time using
getInlineAnchorList()
using document.querySelectorAll()
and only the first button is rendering properly, the rest are unstyled
mantine buttonsUsing Plasmo with Mantine
I was able to successfully use https://mantine.dev/ for all my react components in the google extension popup, but I'm not able to get it to properly render the components in the injected react components
Storage hook `undefined` during initial render
Hey! I'm using the
useStorage
hook and noticed that during the initial render, it is undefined
(default value) and then gets populated with the value from storage. I understand why this is the case (async data store vs sync rendering), however is there any way we can make it so that all storages are loaded before the rest of the application shows (i.e. no initial render with default values)?Wrong offered argument in PlasmoMountShadowHost
https://github.com/PlasmoHQ/plasmo/blob/51010593098d2871dc49c93b0cb22ba415221298/cli/plasmo/src/type.ts#L55-L60
compared to
https://github.com/PlasmoHQ/examples/blob/de42aa8fe74e2b025fa582112d59795c7c04ba4e/with-svelte/contents/plasmo-inline.svelte#L15-L20...
How to access the current anchor in CSUI
Would it be possible to get current anchor inside the content component?
Like if I'm mounting to multiple anchors and the logic needs to get input from a child element of that specific element
@Jenya : https://discord.com/channels/946290204443025438/946290204904390690/1057702630404653057...
Svelte - Unexpected token (parse-error)
It seems like Parcel fails to parse this in a Svelte popup:
```ts
const errorMessage = {
youtube: "Cannot assign. Used by YouTube",
alreadyInUse: "Cannot assign. Already in use"...
Multiple Svelte CSUI injections
Sometimes, I'd like my extension to inject multiple components onto the web page, and some other times the web page is simply an SPA, so it happens that I will end up injecting multiple CSUIs
Any projection on when Plasmo will support it?...
Best way to store JSON with storage API
Hello 😁 ! I am going to store some configuration data (in JSON) using the storage API. I am wondering what is the best way to do it using the
usestorage
hook. I was thinking of somehow using the onInit
argument to parse the JSON but I'm not sure if that will work.HMR Very Slow
I have to save my files a few times, and then still wait a while before any changes are reflected. The tab reloads, but the changes aren't present, any ideas?
getStyle doesn't work
I have
content.ts
:
```ts
export const config: PlasmoContentScript = {...};
export const getStyle: PlasmoGetStyle () => {...How do I check the size of my Plasmo cache
The cache is located in
.plasmo/cache
. The size of these files are the size of your cache.