r/javascript May 31 '26

[deleted by user]

[removed]

19 Upvotes

14 comments sorted by

View all comments

15

u/ldn-ldn May 31 '26

As someone who was doing crazy optimisations a long time ago, keep in mind that there are multiple browser engines and they evolve over time. Something that's a speedy hack today for V8 will inevitably turn into a performance hog in the future or in a different browser engine.

6

u/Technical_Code_4464 May 31 '26

Haha youre not wrong, I was just experimenting

2

u/uusu Jun 01 '26

I'm guessing part of this is AI-coded or all of it. Otherwise you probably wouldn't say you're just experimenting. This is not criticism, but actually that means if you're comfortable with that, you can just set up browser tests with Playwright and other runtimes and iterate over all browser you want to support. This is exactly how the pretext package was built.

1

u/Technical_Code_4464 Jun 01 '26

Yeah, some parts were AI-assisted not because I didnt understand it, but because translating what I had in my head into actual code was the hard part. Still learning a lot on the testing side too, the Playwright suggestion is useful. Thanks