Saturday, September 6, 2014

Maintainable Javascript

Key takeaways from Maintainable Javascript.
  1. Borrow the book is better than buy the book. I finally finished reading this book in past 3 weeks' limited spare time.
  2. Programs are meant to be read by humans and only incidentally for computers to execute. - Donald Knuth
  3. Need consistent Javascript code styles for Basic formatting, comments, statements and expressions, variables, functions and operators.
  4. Need good programming practices
    1. Loose coupling of UI layers (MVC)
    2. Avoid globals
    3. Throw your own errors (throw new Error('name is required'))
    4. Don't modify objects you don't own
  5. Documentation - JSDoc tooltik
  6. Automated Testing - Jasmine, PhantomJS, Selenium
  7. Continous Integration (CI system) -  Jenkins, Continuum, BuildBot, Cruise Control, Gradle

No comments:

Post a Comment