Great job - works great!!! I tried the same for windows but I can not find a function like AddUserScript() and CoreWebView2.AddHostObjectToScript(...) throws the error: 'The group or resource is not in the correct state to perform the requested operation.'
Could you PLEASE extend you example for Windows?