Live data from Hacker News

Playwright for .NET is now stable

github.com

61–66 of 66 posts

Re: Playwright for .NET is now stable

#61
post #38

Earlier quoted context omitted.

Because for some teams it's easier to write tests in plain C# with NUnit/xUnit libs.

But why? Why shoehorn everything into a single technology? Is it so that certain people never have to learn anything else in their entire life anymore?

Nobody here wants to say it, so I'll just say it and face the downvotes...

JavaScript as a server-side technology sucks. It was cool back in 2010 when NodeJS first came out and event loops were all the rage. But .NET is now 10x faster than NodeJS, statically typed, has better community support, better tooling, broader official libraries, better package manager, and as a bonus it's not JavaScript. The productivity and performance of .NET with Visual Studio is just unmatched.

Re: Playwright for .NET is now stable

#62
post #51
post #44

Earlier quoted context omitted.

Well, a pretty good reason is that C# is statically typed, which a lot of developers prefer. It's arguably a much more powerful language than JavaScript too. Personally, I work with both C# and JavaScript, and I'd happily use the C# version of Playwright to write and run UI tests.

Well, a pretty good reason is that C# is statically typed, which a lot of developers prefer. Don't know, everyday I see more and more C# devs preferring Typescript for new projects.

For the frontend of a SPA, sure, I prefer Typescript over JavaScript for that kind of thing.

But for the backend (APIs, services, whatever), I'd personally still go with C# any day - it really is a wonderful language, and the available tooling is fantastic.

Re: Playwright for .NET is now stable

#63

Oh, I didn't know this existed. Definitely going to try this. I'm currently using Puppeteer Sharp ( https://github.com/hardkoded/puppeteer-sharp ) and something like: > await page.GotoAsync(" https://playwright.dev/dotnet "); > await page.ScreenshotAsync(new PageScreenshotOptions() { Path = "screenshot.png" }); Is broken, if you have background images in CSS the screenshot happens after Page Load is completed but bef…

As others mentioned, the same guy is involved in Playwright. One thing I wanted to mention is that he is extremely responsive. I posted several issues a number of years ago and he fixed them pronto. And even dug into the underlying Chromium issues.

Re: Playwright for .NET is now stable

#64

Earlier quoted context omitted.

But why? Why shoehorn everything into a single technology? Is it so that certain people never have to learn anything else in their entire life anymore?

Nobody here wants to say it, so I'll just say it and face the downvotes... JavaScript as a server-side technology sucks. It was cool back in 2010 when NodeJS first came out and event loops were all the rage. But .NET is now 10x faster than NodeJS, statically typed, has better community support, better tooling, broader official libraries, better package manager, and as a bonus it's not JavaScript. The productivity and…

IMO, the only true part in your comparison is that .NET is faster than nodejs.

Re: Playwright for .NET is now stable

#65

Earlier quoted context omitted.

Have you tried selinium and phantomjs headless ? I was using that a few years ago and it worked very well.

I couldn't get it working in an AWS Lambda. May work now but I haven't had time this year to re-visit that project.

Could be the same reason why this doesn't work as an Azure Function either:

https://github.com/microsoft/playwright-dotnet/issues/1076

Re: Playwright for .NET is now stable

#66

Oh, I didn't know this existed. Definitely going to try this. I'm currently using Puppeteer Sharp ( https://github.com/hardkoded/puppeteer-sharp ) and something like: > await page.GotoAsync(" https://playwright.dev/dotnet "); > await page.ScreenshotAsync(new PageScreenshotOptions() { Path = "screenshot.png" }); Is broken, if you have background images in CSS the screenshot happens after Page Load is completed but bef…

As others mentioned, the same guy is involved in Playwright. One thing I wanted to mention is that he is extremely responsive. I posted several issues a number of years ago and he fixed them pronto. And even dug into the underlying Chromium issues.

Yeah he’s good. Helped me with an issue I had. The particular issue I have is actually in puppeteer. But I need a .net library so that’s why I mentioned it.

Not trying to downplay his project cos it’s actually really good.

Post reply on HN