```import { callbackify } from "util" define("Hea...
# suitecommerce
j
Copy code
import { callbackify } from "util"

define("HeaderCustomizations.View", [
    "Backbone", "header_customizations.tpl"
], function(Backbone, header_customizations_tpl){
    
    console.log('Inside View');

    return Backbone.View.extend({
        
        template: "header_customizations_tpl",

        initialize: function(options){
            this.message = options.container.getConfig("announcement.message") || "This is a sample announcement!";

            this.firstname = options.profileData.firstname;
        },

        events:{
            
            "click [data-action='close']" : 'hideBanner'
        },

        hideBanner: function(){
            this.$el.remove();
        },

        getContext: function(){
            return{
                message: this.message,
                firstname: this.firstname
            }
        }
    })
})