Skip to content

Instantly share code, notes, and snippets.

@diegoeche
Created December 12, 2009 16:51
Show Gist options
  • Save diegoeche/254963 to your computer and use it in GitHub Desktop.
Save diegoeche/254963 to your computer and use it in GitHub Desktop.
[<JavaScriptType>]
type Test =
inherit Web.Control
new () = {}
[<JavaScript>]
override this.Body =
let container = Div [ StyleAttribute "width:500px; height:300px;" ]
if Google.Maps.Base.BrowserIsCompatible() |> not then
JavaScript.window.alert "Your browser is not compatible with Google Maps"
else
let map = new Google.Maps.Core.Map2(container)
map.setCenter(new LatLng(37.4419, -122.1419), 14.)
container
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment