Results 1 to 2 of 2

Thread: Declaration error when following 'Getting Started' tutorial

  1. #1
    Sencha User
    Join Date
    Jul 2012
    Posts
    2
    Vote Rating
    0
      0  

    Default Unanswered: Declaration error when following 'Getting Started' tutorial

    I have been following this tutorial http://docs.sencha.com/touch/2-0/#!/guide/getting_started to create this application http://docs.sencha.com/touch/2-0/#!/guide/first_app which involves creating a small site with a Home page, a Contact page, and a Blog page.

    Everything went fine for the first two pages, but when I reached the Blog page, I hit an error I can't work out.

    Uncaught Error: The following classes are not declared even if their files have been loaded: 'GS.view.Blog'. Please check the source code of their corresponding files for possible typos: 'app/view/Blog.js

    This is my code on blog.js
    PHP Code:
    Ext.define('GS.view.Blog', {
        
    extend'Ext.navigation.View',
        
    xtype'blog'
    This is my code on main.js
    PHP Code:
      xtype'blog' }, 
    and this is my code on app.js
    PHP Code:
    views: ['Main''Home''Contact''Blog'], 
    As you can see, the declarations are all correct. Or at least, they look correct to me.
    But it's still not running.

    I'm sure it's a simple mistake I've made. Does anyone know how to fix it?

  2. #2
    Sencha - Sr Software Engineer mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    39,339
    Answers
    3887
    Vote Rating
    1297
      0  

    Default

    First issue is your file blog.js or Blog.js?
    Mitchell Simoens @LikelyMitch
    Sencha Inc, Senior Software Engineer
    ________________
    Learn BBCode and use it!

    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

Tags for this Thread

Posting Permissions

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