webview/webview ? reverse-engineered prompt

Reverse engineered prompt

Build me a tiny cross platform C and C++ library that lets an app show a simple desktop window with embedded web content, like a small browser view inside the app.

I want it to work on Linux, macOS, and Windows, using the native web engine on each platform, and I want both C and C++ APIs so I can create a window, set the title and size, load HTML or a URL, run it, and close it cleanly. It should also support calling JavaScript from C or C++, and calling back into the native code from JavaScript.

Please include a clean build setup, a few working examples, and a way to build it as a single header if possible. Make sure it feels easy to drop into another project, and add enough docs in the code so I can understand how to use it. If you need to check the latest platform docs while wiring up the native web views, go ahead and do that.

Are you gonna build this?

make sure you review the code using coderabbit

Try freeSponsored — opens CodeRabbit in a new tab