import { BrowserWindow } from '@mobrowser/api';
import { native } from './gen/native';

// Create a new window and load Google.com.
const win = new BrowserWindow()
win.browser.loadUrl('https://google.com')
win.setSize({ width: 1000, height: 800 })
win.show()

// Call the native C++ function and print the result.
const msg = await native.greet.SayHello({ name: 'John Doe' })
console.log(`Native C++ module says: ${msg.value}`)
