Besides it is proven to be capable of doing great things (Google Apps) it was great help to us too. It provided us with large number of widgets, cross browser support (including mobile devices) and dedicated tools such as Closure Compiler and templating engine.
Take advantage of OO design and pair it with the power of this scripting language. Application shouldn’t be just a set of scripts that run as they are loaded into browser.
- Adopt Java style
- Design in detail
Design your client app with clean separation of concerns between modules and classes. Design it to be multi tier application. It is more complicated to do, but it will help maintainability and boost understandability.
- Use packages and namespaces as source organization
- Use “One class, one file” rule
This is the easiest way to organize your code. You will have a bunch of files, that’s true, but you will know exactly what every file contains and what every class does (with assumption you were giving classes logical names). Adding to the UberCustomer example from the above, file containing the class should be called UberCustomer.js. I bet this sounds familiar.
- Separate component communication by using event bus
Don’t let you code become tangled cause every class can directly call any other class’s functions. Make different parts of the app communicate with each other using messages, i.e. events. Ones should fire those messages, others should listen. Just like in real communication – if everybody talk at the same time, nothing can be heard.
- Document, document, document
If infrastructure exists, create project wiki pages – this will help your team in discussing problems and solutions. When solution is implemented, write an article about how it’s done – great help when tring to remember what was done or when new team member is getting introduces to the project.
- Automate build process
If we take a minute and think a bit about what is said, we could agree that it is nothing revolutionary. Every application, written in no matter which language, should be developed having in mind good organization, easy maintenance and steep learning curve.
MapReduce testing with MRUnit
In one of the previous posts on our blog , my colleague gave us a nice example how to test a map/reduce job. A starting point was the implementation of it which was done using Apache Pig. I would like to extend his example in this post by adding a little...
1.6.2014 | 5 Minuten Lesezeit
Map/Reduce with Hadoop and Pig
Big data. One of the buzz words of the software industry in the last decade. We all heard about it but I am not sure if we actually can comprehend it as we should and as it deserves. It reminds me of the Universe – mankind has knowledge that it is big...
- Big Data
25.10.2012 | 7 Minuten Lesezeit
Android persistence accelerated – revisited
Finally, after quite a while, we found some free time to work on Android persistence library I wrote about in this blog post . Knowing we have very tight schedule, as always, we wanted to make sure library is ready to be used. So, we took a good look...
9.5.2012 | 3 Minuten Lesezeit
Android persistence accelerated – small inhouse ORM
A person easily gets used to comfort and luxury. In every segment of life. Bigger apartment, better car, new phone, bigger kitchen sink… Those are all good things. But, a person easily forgets how it was before the progress happened. Nervousness in the...
4.4.2011 | 5 Minuten Lesezeit
Android, Maven and Hudson. Pardon me, Jenkins.
Android platform is based on Java but is somehow different. It compiles into Dalvik rather than into Java byte code and runs in emulator which is enough to make some of your standard Java tools fail and become unusable. There was one specific problem...
16.2.2011 | 6 Minuten Lesezeit
On your mark, get set, present!
In my inner dialog about GWT I mentioned that we used Model-View-Presenter approach in our project – MVP plus event bus mechanism. It is quite interesting approach, could be labeled as overhead, but it is with no doubt useful. This time, I would like...
- Agile methods
27.11.2010 | 4 Minuten Lesezeit
Inner dialog on GWT – benefits and drawbacks
Project I’m currently working on really interested and intrigued me. Main reason is GWT, technology I had chance to meet more than once, but never to get to know it very well. When I heard that it will be used, I was very enthusiastic about it, because...
- Agile methods
1.11.2010 | 5 Minuten Lesezeit
Dein Job bei codecentric?
Agile Developer & Consultant (w/d/m)
An allen Standorten
Gemeinsam bessere Projekte umsetzen.
Wir helfen Deinem Unternehmen.
Du stehst vor einer großen IT-Herausforderung? Wir sorgen für eine maßgeschneiderte Unterstützung. Informiere dich jetzt.
Hilf uns, noch besser zu werden.
Wir sind immer auf der Suche nach neuen Talenten. Auch für dich ist die passende Stelle dabei.
Do you still have questions? Just send me a message.