Widget options

Typically, adding the Weavy widget script to your application or website is quite enough to get you started. For more advanced scenarios you may want to tweak the default options a bit to make your Weavy widget look and behave the way you want it to.

Using options

Specify options by passing an object with properties when constructing the widget. The standard url is set to your installation, but you may override it to point to a development server for instance.

    var widget = new WeavyWidget({
        url: '[weavyinstallation]'

Default options

These options are general for all WeavyWidget instances and may be overridden in Widget API options.

Name Default Description
container : Element   Container where the widget should be placed. If no Element is provided, a <section> is created next to the <body>-element.
className : string   Additional classNames added to the widget.
https : string "adaptive" How to enforce https-links.
  • “force” makes all urls https.
  • “adaptive” enforces https if the calling site uses https.
  • “default” makes no change.
init : boolean true Should the widget initialize automatically.
isMobile : boolean   Indicates if the browser is mobile. Defaults to the RegExp expression /iPhone|iPad|iPod|Android/i.test(navigator.userAgent)
includePlugins : boolean true Whether all registered plugins should be enabled by default. If false, then each plugin needs to be enabled in plugin-options.
overlay : Element   Element to use for overlay purposes. May for instance use the overlay of another WeavyWidget instance.
url : string   The URL to the Weavy-installation to connect to. It defaults to the url of your installation.

Plugin options

The widget has built-in support for javascript plugins. You may configure or disable plugins in your options. You can set options for any plugin under options.plugins.pluginname. All options for custom plugins will also be set under options.plugins[custom_plugin_name].

Plugin option defaults

  • Alert - Displaying alerts with messages.
  • Attach - Functionality for attaching files from dropbox, O365, Google etc.
  • Authentication - Sign in functionality when not using SSO.
  • Badge - Handles badges for notifications and messages.
  • Bubbles - State machine for handling spaces connected to urls.
  • Context - Connect spaces to urls and provide browser context links.
  • Dock - The UI component containing bubble buttons and panel handling.
  • Fallback - Opening panels in popup windows when frames are disallowed.
  • Messenger - The Weavy Messenger.
  • Notifications - Displays notifications in the browser window.
  • Panels - Manager for creating and handling panels.
  • Personal - Panel containing user profile, notifications, stars and drafts.
  • Position - Dock minimizing and drag’n’drop.
  • Preview - Displaying images and documents in full browser window.
  • SSO (Single Sign On) - Using JWT for providing seamless authentication.
  • Start - Panel for the weavy start page for opening spaces and finding people.
  • Theme - Loading and injecting styles into the WeavyWidget.
  • Upgrade - Checking if new versions of the widget are available.

Example: Position plugin options

var widget = new WeavyWidget({
  url: '[weavyinstallation]',
  plugins: {
    position: {
        positionClassName: 'weavy-collapsed',
        snappingX: 4,
        snappingY: 4,
        minimizeDelay: 15000

Disabling plugins

Simply set the options to false for the plugin you want to disable.

var widget = new WeavyWidget({
  url: '[weavyinstallation]',
  plugins: {
    position: false

Option presets

Use option preset configurations for simple configurations of common options. You may add your own presets also. The presets may be merged with custom options when you create a new WeavyWidget(), since the contructor accepts multiple option sets.

Read more about presets in the Widget API

Name Description
WeavyWidget.presets.core Disable all plugins.
WeavyWidget.presets.panel Minimal plugin set to only have one or more panels instead of the full widget dock.


// Load the minimal widget core without any panels.
var widget = new WeavyWidget(WeavyWidget.presets.core, { url: "https://myweavysite.com" });

Accessing the options

After making a new WeavyWidget() you can access all options through widget.options.

var widget = new WeavyWidget(
  url: '[weavyinstallation]'

var currentOptions = widget.options;

Accessing defaults

The default settings for the WeavyWidget is accessed through WeavyWidget.defaults. These settings is the ones being used as default when you make a new WeavyWidget().

Widget API

For even more control of the Weavy widget and its behavior you should have a look at the Widget API Reference.