Edit this page

fn Object

An alias to the prototype of the class. Often used to call methods of the base class.

Example - use the prototype to call base methods

// Create a base class
var Animal = kendo.Class.extend({
    // The `init` method will be called when a new instance is created
    init: function(legs) {
       this.legs = legs;

// Inherit from that class

var Bird = Animal.extend({
    init: function() {
        // Use the `fn` field to call the `init` method of the base class (Animal)
        Animal.fn.init.call(this, 2);

var birdie = new Bird();

console.log(birdie.legs); // outputs 2
Is this article helpful? Yes / No
Thank you for your feedback!

Give article feedback

Tell us how we can improve this article