Doc: edited JavaScript extensions docs

Fixed grammar and style issues and typos.

Change-Id: Ic80bd3f9fb96047d390ff0cdcbc382a4939a9892
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>