One Super and Two SubClasses in JavaScript (Hindi)

แชร์
ฝัง
  • เผยแพร่เมื่อ 11 ก.ย. 2024
  • One Super and Two SubClasses in JavaScript
    You can find out our HTML Complete Video tutorials :
    goo.gl/O254f9
    CSS Complete Video Tutorial Playlist:
    goo.gl/On2Bh1
    Feel free to share this video
    JavaScript Complete Video Tutorial Playlist
    goo.gl/A517jQ
    Check Out Our Other Playlists:
    / geekyshow1
    SUBSCRIBE to Learn Programming Language !
    goo.gl/glkZMr
    Learn more about subject:
    www.geekyshows....
    __________________________________________________________
    If you found this video valuable, give it a like.
    If you know someone who needs to see it, share it.
    If you have questions ask below in comment section.
    Add it to a playlist if you want to watch it later.
    ___________________________________________________________
    T A L K W I T H M E !
    Business Email: contact@geekyshows.com
    TH-cam Channel: / geekyshow1
    Facebook: / geekyshow
    Twitter: / geekyshow1
    Google Plus: plus.google.co...
    Website: www.geekyshows....
    ___________________________________________________________
    Make sure you LIKE, SUBSCRIBE, COMMENT, and REQUEST A VIDEO :)
    ___________________________________________________________

ความคิดเห็น • 44

  • @himanshu2168
    @himanshu2168 5 ปีที่แล้ว +6

    please explain why we reset the inheritance constructor?

  • @kingkie9536
    @kingkie9536 4 ปีที่แล้ว +1

    Sabse jyada time laga apki iss video ko samghne ar cover karne me..........but maja ayya

  • @prachipatil5996
    @prachipatil5996 2 หลายเดือนก่อน +1

    Why we reset the inheritance constructor?

  • @kajalkashyap4068
    @kajalkashyap4068 5 ปีที่แล้ว +2

    thanks for awesome video but ye smjh nhi aaya k constructor ko reset q krte h, bina reset kiye b work krta h...... please reply

    • @sam-001
      @sam-001 2 ปีที่แล้ว

      Same problem

  • @satyasahoo26
    @satyasahoo26 4 ปีที่แล้ว

    Very helpful tutorial.

  • @ajazamin9843
    @ajazamin9843 2 ปีที่แล้ว

    sir here i think is a demerit
    function extend (child,parent) {
    child.prototype = Object.create(parent.prototype);
    child.prototype.constructor = child;
    } is fine, but when i try to add
    child.prototype.anything = function () {
    return(this.xyz);

    }
    and if i try to access this function through the object of its class it shows this function is not defined. why?

  • @avkexpress8029
    @avkexpress8029 5 ปีที่แล้ว

    owsm sir g very helpful to learn

  • @sanjaygarg1146
    @sanjaygarg1146 4 ปีที่แล้ว +2

    Sir please tell me why we are reset constructor ?

    • @akshdesai3390
      @akshdesai3390 2 หลายเดือนก่อน +1

      because by default prototype object has 2 fields. one is constructor and second is prototype. but for this line "Lenovo.prototype = Object.create(Mobile.prototype);" we override the prototype object and now it has not second field called constructor. so that's why we need to reset the constructor. and need to put this line as well "Lenovo.prototype.constructor = Lenovo;"

  • @wildturtle2416
    @wildturtle2416 3 ปีที่แล้ว

    nice explanation

  • @amolbonde6318
    @amolbonde6318 4 ปีที่แล้ว

    Well described

  • @user-gg5nh1mf6l
    @user-gg5nh1mf6l 5 ปีที่แล้ว +2

    You are great.
    but how can I memorize those code? what should I do for that?

    • @_samirdahal
      @_samirdahal 5 ปีที่แล้ว +2

      When you do big projects then you'll remember it automatically. Just practice, practice, practice.

  • @shivbaboo3491
    @shivbaboo3491 2 ปีที่แล้ว +1

    Sir , why you make constructor reset ? samsung.prototype.constructor = samsung ..

    • @akshdesai3390
      @akshdesai3390 2 หลายเดือนก่อน

      because by default prototype object has 2 fields. one is constructor and second is prototype. but for this line "Lenovo.prototype = Object.create(Mobile.prototype);" we override the prototype object and now it has not second field called constructor. so that's why we need to reset the constructor. and need to put this line as well "Lenovo.prototype.constructor = Lenovo;"

  • @sam-001
    @sam-001 2 ปีที่แล้ว +1

    Mera work nahi ho raha inherent function

  • @alltechsimplified2134
    @alltechsimplified2134 4 ปีที่แล้ว

    thanks

  • @magictricks9954
    @magictricks9954 5 ปีที่แล้ว

    sir plz its your first video out of 86 that is a little confusing plz sir make a video again on this topic

  • @adeelnaqvi1064
    @adeelnaqvi1064 5 ปีที่แล้ว +1

    Why we need reset constructor in inheritance?

    • @akshdesai3390
      @akshdesai3390 2 หลายเดือนก่อน

      because by default prototype object has 2 fields. one is constructor and second is prototype. but for this line "Lenovo.prototype = Object.create(Mobile.prototype);" we override the prototype object and now it has not second field called constructor. so that's why we need to reset the constructor. and need to put this line as well "Lenovo.prototype.constructor = Lenovo;"

  • @mohammadkaisam4099
    @mohammadkaisam4099 5 ปีที่แล้ว

    sir agr super class k prototype k method me koi argument de na ho tw kese de ge

  • @_samirdahal
    @_samirdahal 5 ปีที่แล้ว

    Sir recursion k liye video hai, please reply?

  • @raeesh2373
    @raeesh2373 4 ปีที่แล้ว +2

    why we are using constructor reset ?? alert("plz any one can clear my doubt")

    • @akshdesai3390
      @akshdesai3390 2 หลายเดือนก่อน

      because by default prototype object has 2 fields. one is constructor and second is prototype. but for this line "Lenovo.prototype = Object.create(Mobile.prototype);" we override the prototype object and now it has not second field called constructor. so that's why we need to reset the constructor. and need to put this line as well "Lenovo.prototype.constructor = Lenovo;"

  • @harrysingh4915
    @harrysingh4915 4 ปีที่แล้ว

    Sir iske baare mei batao plzz constructor reset kyu krte hai???

  • @deeprajmazumder6261
    @deeprajmazumder6261 4 ปีที่แล้ว

    bro aap ES6 ka use nehi kar rahe ho...getter, setter etc ka bhi use nehi kar rahe

  • @anujsharma-og2ts
    @anujsharma-og2ts 5 ปีที่แล้ว

    // class
    var Mobile=function (){
    };
    // prtotype method
    Mobile.prototype.getModel=function(){ return this.model;}

    var mob=new Mobile();
    document.write(mob.getModel());
    sir mujhe yahi par parameter deke model print karana ho to sir hum karenge, sir please help and reply to me

  • @og_roxy14
    @og_roxy14 4 ปีที่แล้ว

    Bhiya hmlog constructor kyu reset krte h iski kya jrurat h ??

  • @shubhambiniwale9623
    @shubhambiniwale9623 5 ปีที่แล้ว +2

    *Samsung.prototype.constructor = Samsung;*
    Line kyu likhte hai sir? uski kya jarurat hai? usse code me kya effect hoga?

    • @johncena-qo2hq
      @johncena-qo2hq 4 ปีที่แล้ว +1

      Reset constructor
      Is code se constructor ko reset krte h

    • @shubhambiniwale9623
      @shubhambiniwale9623 4 ปีที่แล้ว

      @@johncena-qo2hq thanks John cena.😊👍

  • @surajankita1
    @surajankita1 4 ปีที่แล้ว

    what is the use of call(this)?..by this also we r accessing other members?

    • @raeesh2373
      @raeesh2373 4 ปีที่แล้ว

      accotding to c++ when access to funtion member that time we need to call it thas why we are using here some concept here but i am not sure

    • @sam-001
      @sam-001 2 ปีที่แล้ว

      @@raeesh2373 java karani chahiye yaa cpp

  • @sumitmakwana6104
    @sumitmakwana6104 5 ปีที่แล้ว +1

    why reset the constructor ??

    • @akshdesai3390
      @akshdesai3390 2 หลายเดือนก่อน

      because by default prototype object has 2 fields. one is constructor and second is prototype. but for this line "Lenovo.prototype = Object.create(Mobile.prototype);" we override the prototype object and now it has not second field called constructor. so that's why we need to reset the constructor. and need to put this line as well "Lenovo.prototype.constructor = Lenovo;"

  • @pushkargoyal4278
    @pushkargoyal4278 3 ปีที่แล้ว

    i can do this also
    Object.call(Mobile());

  • @creativity6495
    @creativity6495 5 ปีที่แล้ว

    confusing

  • @anishkumar221
    @anishkumar221 4 ปีที่แล้ว

    Why getmodule ?????

    • @og_roxy14
      @og_roxy14 4 ปีที่แล้ว

      Ye function h getModel() nam se yeha hum koi b namm rakh sakte h jaise ur name is anish to...getAnish()...etc

  • @Raghav-Sharma
    @Raghav-Sharma 3 ปีที่แล้ว

    You are too predictable now I guess your object name without seeing

    • @geekyshows
      @geekyshows  3 ปีที่แล้ว

      It will help to understand the concept easily. I also follow one pattern to explain various languages and frameworks so if A Person learns Django at Geekyshows He/She can easily grab other framework like Laravel at Geekyshows. I try to make them similar as much as possible.

    • @Raghav-Sharma
      @Raghav-Sharma 3 ปีที่แล้ว

      @@geekyshows yes I know that it's really convenient and easy to understand take this as complement thanks to your hard work I can easily understand the basics of the js