---
to: widget.ts
---
import { defineWidget } from '@wix/blocks';

export default defineWidget('<%- id -%>', ($w, $widget) => {
  $w.onReady(() => {
    console.log('Widget is ready');
  });

  $widget.onPropsChanged((oldProps, newProps) => {
    console.log('Widget props changed', {
      oldProps,
      newProps,
    });
  });
  
  return {
    myPublicFunction() { }
  };
});
