preact-devtools icon indicating copy to clipboard operation
preact-devtools copied to clipboard

Preact Elements tab does not show components as a tree

Open aptash opened this issue 3 years ago • 6 comments

Hello!

Often "Elements" tab shows components in a view different then a tree-view. I have to switch between Preact tabs to restore a tree-view. Preact Developer Tools: 4.2.0

image

aptash avatar Jun 02 '22 07:06 aptash

Looks like for some reason the window dimensions are wrong during size calculations. From the screenshot I'm assuming it's receiving a value of 0. Haven't been able to reproduce that on my end so far. Does slightly resizing the devtools window work too? If yes than it's definitely a wrong value for the initial window width.

marvinhagemeister avatar Jun 02 '22 10:06 marvinhagemeister

It seems you are right! Slightly resizing the devtools window works alright! The tree became ok at once.

I can not reproduce the problem when I wish. But the problem happens very often during the day.

aptash avatar Jun 02 '22 10:06 aptash

Just put v4.3.1 up for review in the browsers extension stores. The new version should be live soon and contains some improvements to the resizing logic. Let me know if this fixes the issue you're seeing.

marvinhagemeister avatar Jun 06 '22 17:06 marvinhagemeister

Unfortunately I've just got the issue again:

Preact Developer Tools: 4.3.1 image

But today it's the first time after a few hours of using Preact Developer Tools. So in general it became better. Resizing helped as before.

I will try to catch the problem case and to keep you informed

aptash avatar Jun 07 '22 12:06 aptash

Caught it again today after a few hours of using. It was maximised. Exit from maximised mode didn't help. But resizing after that did the job. image

aptash avatar Jun 08 '22 15:06 aptash

Unfortunately it's still happening. I got it yesterday once. And today twice during 2 hours. I use DevTools maximised. image

aptash avatar Jun 16 '22 08:06 aptash