1. #1
    Ext JS Premium Member
    Join Date
    Nov 2008
    Posts
    263
    Vote Rating
    0
    wki01 is on a distinguished road

      0  

    Default applyTo non exist ??

    applyTo non exist ??


    It appears that the property applyTo no longer exists.
    The functionality has been removed or is there an equivalent property?
    Thanks

  2. #2
    Sencha Premium Member
    Join Date
    Jan 2009
    Posts
    204
    Vote Rating
    12
    firefoxSafari will become famous soon enough

      0  

    Default


    I'd like to know the future of applyTo as well.

    I noticed that the config option was no longer in the docs. However, it still works at least in some cases. I tried a simple test with a Panel and a div with some text in it and it worked just fine.

    Which component were you trying to use applyTo on?

  3. #3
    Ext JS Premium Member
    Join Date
    Nov 2008
    Posts
    263
    Vote Rating
    0
    wki01 is on a distinguished road

      0  

    Default


    Inside the source I found this comment.
    I would say that applyTo will no longer be supported.
    Code:
       // This needs to die a horrible death.  For now it's a replaceMarkup, I can't see supporting this methodology going forward.
        /**
         * Apply this component to existing markup that is valid. With this function, no call to render() is required.
         * @param {String/HTMLElement} el
         */
        applyToMarkup: function(el) {
            this.allowDomMove = false;
            this.render(Ext.getDom(el).parentNode, null, true);
        },

  4. #4
    Sencha - Community Support Team Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,251
    Vote Rating
    41
    Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold Condor is a splendid one to behold

      0  

    Default


    It's not that easy anymore to do an applyTo because of the way the rendering process has been restructured in Ext 4.

    That is why applyToMarkup currently replaces the specified element with the component (which is of course not the correct behavior).

  5. #5
    Ext JS Premium Member devtig's Avatar
    Join Date
    Jan 2010
    Location
    Rotterdam, The Netherlands
    Posts
    383
    Vote Rating
    8
    devtig will become famous soon enough

      0  

    Default


    It may be a good idea to have configs, methods, events that have become obsolete, to still be in the ExtJS 4 API docs. Greyed out or something and mentioning the new way of doing it in ExtJS 4.

  6. #6
    Ext JS Premium Member
    Join Date
    Nov 2008
    Posts
    263
    Vote Rating
    0
    wki01 is on a distinguished road

      0  

    Default


    This is a very big problem for me.
    100% of my apps use a make-up already exists at the field level.
    (I use Lotus Domino).
    I wish I had an official response to the development team about the future support of the method applyTo.

    Thanks

  7. #7
    Ext JS Premium Member stevil's Avatar
    Join Date
    Nov 2007
    Location
    Denver, CO
    Posts
    1,045
    Vote Rating
    7
    stevil will become famous soon enough

      0  

    Default


    Quote Originally Posted by Condor View Post
    It's not that easy anymore to do an applyTo because of the way the rendering process has been restructured in Ext 4.

    That is why applyToMarkup currently replaces the specified element with the component (which is of course not the correct behavior).
    I can certainly understand the challenge you face of keeping the architecture clean, fast, and stable. That said, I'm pretty sure there are a lot of Ext JS applications out there that rely on applyTo for legacy-rendered applications (my own included).

    If applyTo is not supported, some other means of transforming HTML will be needed, or I'll have a hard time believing sencha's claim (when announcing Ext JS 4) that the vast majority of applications would just run with the compatibility layer/adapter in place.

  8. #8
    Sencha User
    Join Date
    Nov 2011
    Posts
    9
    Vote Rating
    0
    jafarkhani.shabnam is on a distinguished road

      0  

    Default


    see this to add this property to your extjs

    http://www.sencha.com/forum/showthre...yTo-to-Ext-4.1

  9. #9
    Sencha User
    Join Date
    Nov 2008
    Posts
    3
    Vote Rating
    0
    micolator is on a distinguished road

      0  

    Default


    I replaced "applyTo" by "transform" for a combobox replacing a textField, and it works !

    Hope this helps...

  10. #10
    Ext JS Premium Member
    Join Date
    Jun 2011
    Posts
    218
    Vote Rating
    3
    ontho is on a distinguished road

      0  

    Default


    Quote Originally Posted by micolator View Post
    I replaced "applyTo" by "transform" for a combobox replacing a textField, and it works !

    Hope this helps...
    This just saved my life

Similar Threads

  1. Autogrid in 3.0 does it exist ?
    By michaelc in forum Ext 3.x: Help & Discussion
    Replies: 5
    Last Post: 16 Feb 2011, 9:48 AM
  2. Window exist?
    By danielbertini in forum Ext 3.x: Help & Discussion
    Replies: 1
    Last Post: 3 Nov 2010, 10:49 PM
  3. Does CheckColumn exist?
    By kolaloka in forum Ext 3.x: Help & Discussion
    Replies: 4
    Last Post: 4 Oct 2010, 4:40 AM
  4. ScriptTagProxy does not exist?
    By teddyjas in forum Ext: Q&A
    Replies: 3
    Last Post: 26 Oct 2009, 6:08 AM
  5. How to know the treeNode is exist?
    By qiuxy in forum Ext 2.x: Help & Discussion
    Replies: 4
    Last Post: 6 Dec 2007, 11:36 PM