1. #1
    Ext User
    Join Date
    Mar 2007
    Location
    Boston
    Posts
    349
    Vote Rating
    0
    sjivan is on a distinguished road

      0  

    Default new namespace convention

    new namespace convention


    On his blog, Jack wrote :
    I've already introduced a new namespace in 0.40, Ext. (e.g. Ext.BasicDialog instead of YAHOO.ext.BasicDialog)
    Can you use the Java package convention instead ? ie ext.BasicDialog instead of Ext.BasicDialog?

  2. #2
    Ext User
    Join Date
    Mar 2007
    Posts
    122
    Vote Rating
    0
    moraes is on a distinguished road

      0  

    Default Re: new namespace convention

    Re: new namespace convention


    Quote Originally Posted by sjivan
    Can you use the Java package convention instead ? ie ext.BasicDialog instead of Ext.BasicDialog?
    I prefer anything that follows a more or less strict convention, and if the convention is "namespaces and classes start with uppercase", it's probably better to use Ext.

    Btw, I see the Ext namespace as a move to drop the YAHOO namespace one day. Is this correct? I think this would make sense. Yes, it would break compatibility but it is a find & replace operation to put everything working again.

    Also, it would be nice to have a "code conventions" page on the wiki (I'm sorry but I'm in a rush this month due to a release, but when things calm down I'll be back and contribute with some wiki pages ;-)).

  3. #3
    Sencha User jack.slocum's Avatar
    Join Date
    Mar 2007
    Location
    Tampa, FL
    Posts
    6,955
    Vote Rating
    17
    jack.slocum will become famous soon enough jack.slocum will become famous soon enough

      0  

    Default


    I would love to use ext instead of Ext, but it may clash with local variables. Ext is already pushing it but I doubt there will be variables named Ext (at least I am hoping). Package names should be lowercase (and all sub packages will be) but the root namespace has to be capital to prevent conflicts with local variables.

    Btw, I see the Ext namespace as a move to drop the YAHOO namespace one day. Is this correct? I think this would make sense. Yes, it would break compatibility but it is a find & replace operation to put everything working again.

    Yes the YAHOO namespace is going away. I can't wait! It will remain backwards compatible though, as I will alias Ext as YAHOO.ext and keep code working.

  4. #4
    Ext User
    Join Date
    Mar 2007
    Location
    Boston
    Posts
    349
    Vote Rating
    0
    sjivan is on a distinguished road

      0  

    Default


    Quote Originally Posted by jacksloc
    Btw, I see the Ext namespace as a move to drop the YAHOO namespace one day. Is this correct? I think this would make sense. Yes, it would break compatibility but it is a find & replace operation to put everything working again.

    Yes the YAHOO namespace is going away. I can't wait! It will remain backwards compatible though, as I will alias Ext as YAHOO.ext and keep code working.
    Since YUI-ext is morphing into a full blown library which uses some YUI classes / concenpts rather than an extension of YUI, does a package name "Ext" make that much sense? It's kinda a general non defining namespace. Have you considered coming up with a real name for this project? If not, does "YuiX" have a better ring than "Ext"? Just thinking out loud.

    Sanjiv

  5. #5
    Ext User
    Join Date
    Mar 2007
    Posts
    122
    Vote Rating
    0
    moraes is on a distinguished road

      0  

    Default


    Quote Originally Posted by sjivan
    Since YUI-ext is morphing into a full blown library which uses some YUI classes / concenpts rather than an extension of YUI, does a package name "Ext" make that much sense? It's kinda a general non defining namespace. Have you considered coming up with a real name for this project? If not, does "YuiX" have a better ring than "Ext"? Just thinking out loud.
    I was thinking about this yesterday, Sanjiv, and after questioning the meaning of the name I concluded that "Ext" could actually be a good name, unless there is already a javascript library with a similar name. Because YUI-ext provides a series of tools to extend Javascript itself and our power to make nice looking applications. Well, I think that Ext is fine, sexy and short. Unless there was some other very nice name (like "Koopaloopa" :lol, how would we call it?

    just my 0.02. ;-)

    PS: remember that YuiX still makes reference to YUI, so I guess this is not an option.

  6. #6
    Sencha User jack.slocum's Avatar
    Join Date
    Mar 2007
    Location
    Tampa, FL
    Posts
    6,955
    Vote Rating
    17
    jack.slocum will become famous soon enough jack.slocum will become famous soon enough

      0  

    Default


    sjivan,

    I'm with moraes, I really like Ext. It's short and sweet. Also, I think it allows the existing "brand" awareness for yui-ext to not be completely destroyed.

    Like moraes noted, the meaning is a little different than "Extensions". The idea is to have a new tag line along the lines of "Extending the web experience" or "Extended JavaScript Components" or "Extend your web application" (I am open to suggestions).

  7. #7
    Ext User
    Join Date
    Mar 2007
    Posts
    2
    Vote Rating
    0
    indy is on a distinguished road

      0  

    Default


    Quote Originally Posted by jacksloc
    (I am open to suggestions).
    Hi Jack. What you think of name JSUI ( JavaScript User Interface ) ? :wink:


  8. #8
    Sencha User jack.slocum's Avatar
    Join Date
    Mar 2007
    Location
    Tampa, FL
    Posts
    6,955
    Vote Rating
    17
    jack.slocum will become famous soon enough jack.slocum will become famous soon enough

      0  

    Default


    I thought about different things with UI, the only problem is it "feels" like a Yahoo UI rip off in some way.

  9. #9
    Sencha User
    Join Date
    Mar 2007
    Posts
    62
    Vote Rating
    0
    ilazarte is on a distinguished road

      0  

    Default


    second vote for Ext. I like it because it sounds foundational and no-frills

Similar Threads

  1. Lack of Namespace Awareness.
    By apfelfabrik in forum Community Discussion
    Replies: 0
    Last Post: 30 Mar 2007, 6:17 AM
  2. Closure coding convention suggestion
    By papasi in forum Ext 2.x: Help & Discussion
    Replies: 1
    Last Post: 6 Mar 2007, 6:15 PM
  3. YAHOO.ext.util namespace missing
    By alexpooley in forum Ext 1.x: Bugs
    Replies: 4
    Last Post: 2 Jan 2007, 5:18 AM
  4. Namespace collision in LayoutDialog?
    By ncubeait in forum Ext 1.x: Bugs
    Replies: 7
    Last Post: 7 Dec 2006, 7:11 AM
  5. Fighting Convention
    By hunkybill in forum Sencha Cmd
    Replies: 1
    Last Post: 6 Dec 2006, 8:36 AM

Thread Participants: 4