nunaliit2-js: Add support for widgets

Issue #278