WebSharper Snippets

Snippets and examples of WebSharper code with live demos.


Latest snippets

RSS Feed

Scheduling Timers Using setTimeout() and clearTimeout()

Timers defined using setTimeout() schedule the execution of a function once after a specified number of milliseconds. This method returns a unique i...

Navigation Within the Browser History

The back, forward and go methods of the History object instruct the browser to navigate to a URL relative to the current document in the browser his...

Kendo UI Calendar Widget

Kendo UI offers a cross-browser solution for web pages that require the user to interact with a calendar widget. This simple implementation displays...

Hello Google Maps

This snippet uses the Google Maps API bindings to create a simple map.

Google Visualization Pie Chart

This snippet visualizes the resources breakdown of a web page using a pie chart. The data is displayed as sectors of a two-dimensional circle.

Hello ExtJS

This example uses WebSharper's Ext JS bindings to create a viewport containing a panel.

HTML5 Audio

HTML5 defines the <audio> element as a standard way for native audio playback on a web page. This snippet embeds an MP3 file, Wav and Ogg are also a...

Canvas Line Cap Styles

The lineCap property describes the line cap style used when drawing lines on a canvas. Three options are available: the default butt, round and squa...

Alert Window Interaction

The alert method of the Window object displays a dialog box containing the specified message and waits for the user to dismiss it.

jQuery UI Static Datepicker

This example features a static jQuery UI datepicker. The widget is inlined in the page instead of being embedded in an overlay when .datepicker() is...