Results 1 to 7 of 7

Thread: Coding styleguide

  1. #1
    Ext JS Premium Member
    Join Date
    Mar 2008
    Location
    Moscow
    Posts
    137

    Default Coding styleguide

    I'm writing one more big application based on ExtJS framework and see, that when the amount of code becomes bigger day after day, i have to refactor it to make it more readable/maintainable. So the question : Are there any where coding styleguide for javascript applications based on ExtJS?

  2. #2
    Sencha Premium User evant's Avatar
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    19,257
    Answers
    759

    Default

    What specifically are you wanting to see?
    Twitter - @evantrimboli
    Former Sencha framework engineer, available for consulting.
    As of 2017-09-22 I am not employed by Sencha, all subsequent posts are my own and do not represent Sencha in any way.

  3. #3
    Ext JS Premium Member
    Join Date
    Mar 2008
    Location
    Moscow
    Posts
    137

    Default

    Quote Originally Posted by evant View Post
    What specifically are you wanting to see?
    Something like this : http://google-styleguide.googlecode....criptguide.xml

    With explanations on how you can make your code more readable, like - writing comments(what we expect to see in those comments), moving events handlers from component configuration to class function, maybe splitting configuration in initializecomponent when it has several object one in another & etc. Maybe someone already wrote that stuff ...

  4. #4
    Sencha Premium User evant's Avatar
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    19,257
    Answers
    759

    Default

    I think a lot of the things in that guide are either:

    a) Things common to all JS that should be followed regardless
    b) Things that are common across all languages

    There's certainly some useful things in the linked guide, but a majority of it is just common sense and good all-round coding practice.
    Twitter - @evantrimboli
    Former Sencha framework engineer, available for consulting.
    As of 2017-09-22 I am not employed by Sencha, all subsequent posts are my own and do not represent Sencha in any way.

  5. #5
    Ext JS Premium Member
    Join Date
    Mar 2008
    Location
    Moscow
    Posts
    137

    Default

    The problem for me is that I have new members in the team who I cannot control, and they have strong jQuery background. After this - they try to make every view with XTemplates with big html code which will lead us to problems in future, so the only way for me is such obvious thing as this - coding style guide. so i'm searching for one. If someone did that - it would be great to see it and maybe take some information from it.

  6. #6
    Sencha User Arg0n's Avatar
    Join Date
    Apr 2012
    Location
    Germany
    Posts
    122
    Answers
    12

    Default

    Here you can find some small information:

    http://docs.sencha.com/ext-js/4-2/#!/guide/command_code

    For docblocks I use the JSDuck tags and style:

    https://github.com/senchalabs/jsduck/wiki




  7. #7

    Default

    Finally Sencha does have an official styleguide:

    https://github.com/sencha/code-guidelines

    Marco

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •