SlideShare una empresa de Scribd logo
1 de 8
Descargar para leer sin conexión
JavaScript-udvikling med Emacs

         Kenneth Geisshirt


            2011-11-07
Outline




  JavaScript-udvikling med Emacs
Hvad er JavaScript?



  JavaScript forbindes mest med web-udvikling.
      Proceduralt
      Klasseløst; objekt-orienteret
      Funktionsprogrammering
Hvor finder du JavaScript?

  Mange implementeringer:
      Mozilla: Rhino og Spidermonkey
      Microsoft: Chakra (IE9)
      Apple: JavaScriptCore
      Google: V8 (bruges i Chrome)
  Du finder det også udenfor browseren:
      GNOME (shell extensions, Seed-applikationer)
      Adobe Integrated Runtime (AIR)
      Server-side: Node.js
      Mozilla (extensions til Firefox og Thunderbird)
Flere modes



  Der er flere modes at vælge i mellem:
      js (tidligere Espresso)
      JavaScript
      ECMAScript
      js2 (understøtter p.t. ikke XEmacs)
js2 mode

  js2 er en JavaScript-fortolker i elisp!
       syntax highlighting
       C preprocessor (nej, har aldrig prøvet)
       understøttelse af imenu (se menu bar)
       folde- og flytte-kommandoer
       fremhævelse af syntaksfejl
       kan sætte slut-parenteser
  http://code.google.com/p/js2-mode/
  http://www.emacswiki.org/emacs/Js2Mode
js2 mode - fortsat

  Foldninger:
      C-c C-f - alle funktioner
      C-c C-t - kommentarblok
      C-c C-o - element
  Andet:
      M-q - ombrydning af kommentarer
      C-højre museknap - menu
      M-g n - næste syntaksfejl
      M-C-b - start af blok
      M-C-n - slut af blok
Udfør JavaScript



  Jeg bruger spidermonkey:
      Findes som Debian-pakke
      Kommandoen er js
      Se min .emacs
      Prøv med M-C-x

Más contenido relacionado

Más de Kenneth Geisshirt

Unleash your inner console cowboy
Unleash your inner console cowboyUnleash your inner console cowboy
Unleash your inner console cowboyKenneth Geisshirt
 
Tips and tricks for building high performance android apps using native code
Tips and tricks for building high performance android apps using native codeTips and tricks for building high performance android apps using native code
Tips and tricks for building high performance android apps using native codeKenneth Geisshirt
 
Is the database a solved problem?
Is the database a solved problem?Is the database a solved problem?
Is the database a solved problem?Kenneth Geisshirt
 
Unleash your inner console cowboy
Unleash your inner console cowboyUnleash your inner console cowboy
Unleash your inner console cowboyKenneth Geisshirt
 
Building High Performance Android Applications in Java and C++
Building High Performance Android Applications in Java and C++Building High Performance Android Applications in Java and C++
Building High Performance Android Applications in Java and C++Kenneth Geisshirt
 
Unleash your inner console cowboy
Unleash your inner console cowboyUnleash your inner console cowboy
Unleash your inner console cowboyKenneth Geisshirt
 
Naturvidenskabsfestival 2012
Naturvidenskabsfestival 2012Naturvidenskabsfestival 2012
Naturvidenskabsfestival 2012Kenneth Geisshirt
 
Hadoop - the data scientist's toolbox
Hadoop - the data scientist's toolboxHadoop - the data scientist's toolbox
Hadoop - the data scientist's toolboxKenneth Geisshirt
 
Introduction to JavaScript for Modern Software Development
Introduction to JavaScript for Modern Software DevelopmentIntroduction to JavaScript for Modern Software Development
Introduction to JavaScript for Modern Software DevelopmentKenneth Geisshirt
 

Más de Kenneth Geisshirt (13)

Node.js extensions in C++
Node.js extensions in C++Node.js extensions in C++
Node.js extensions in C++
 
Unleash your inner console cowboy
Unleash your inner console cowboyUnleash your inner console cowboy
Unleash your inner console cowboy
 
Tips and tricks for building high performance android apps using native code
Tips and tricks for building high performance android apps using native codeTips and tricks for building high performance android apps using native code
Tips and tricks for building high performance android apps using native code
 
Is the database a solved problem?
Is the database a solved problem?Is the database a solved problem?
Is the database a solved problem?
 
Unleash your inner console cowboy
Unleash your inner console cowboyUnleash your inner console cowboy
Unleash your inner console cowboy
 
Extending Node.js using C++
Extending Node.js using C++Extending Node.js using C++
Extending Node.js using C++
 
Building High Performance Android Applications in Java and C++
Building High Performance Android Applications in Java and C++Building High Performance Android Applications in Java and C++
Building High Performance Android Applications in Java and C++
 
Sociale netværk
Sociale netværkSociale netværk
Sociale netværk
 
Unleash your inner console cowboy
Unleash your inner console cowboyUnleash your inner console cowboy
Unleash your inner console cowboy
 
Naturvidenskabsfestival 2012
Naturvidenskabsfestival 2012Naturvidenskabsfestival 2012
Naturvidenskabsfestival 2012
 
Hadoop - the data scientist's toolbox
Hadoop - the data scientist's toolboxHadoop - the data scientist's toolbox
Hadoop - the data scientist's toolbox
 
Introduction to JavaScript for Modern Software Development
Introduction to JavaScript for Modern Software DevelopmentIntroduction to JavaScript for Modern Software Development
Introduction to JavaScript for Modern Software Development
 
Kendthed og vigtighed
Kendthed og vigtighedKendthed og vigtighed
Kendthed og vigtighed
 

JavaScript/Emacs integration

  • 1. JavaScript-udvikling med Emacs Kenneth Geisshirt 2011-11-07
  • 3. Hvad er JavaScript? JavaScript forbindes mest med web-udvikling. Proceduralt Klasseløst; objekt-orienteret Funktionsprogrammering
  • 4. Hvor finder du JavaScript? Mange implementeringer: Mozilla: Rhino og Spidermonkey Microsoft: Chakra (IE9) Apple: JavaScriptCore Google: V8 (bruges i Chrome) Du finder det også udenfor browseren: GNOME (shell extensions, Seed-applikationer) Adobe Integrated Runtime (AIR) Server-side: Node.js Mozilla (extensions til Firefox og Thunderbird)
  • 5. Flere modes Der er flere modes at vælge i mellem: js (tidligere Espresso) JavaScript ECMAScript js2 (understøtter p.t. ikke XEmacs)
  • 6. js2 mode js2 er en JavaScript-fortolker i elisp! syntax highlighting C preprocessor (nej, har aldrig prøvet) understøttelse af imenu (se menu bar) folde- og flytte-kommandoer fremhævelse af syntaksfejl kan sætte slut-parenteser http://code.google.com/p/js2-mode/ http://www.emacswiki.org/emacs/Js2Mode
  • 7. js2 mode - fortsat Foldninger: C-c C-f - alle funktioner C-c C-t - kommentarblok C-c C-o - element Andet: M-q - ombrydning af kommentarer C-højre museknap - menu M-g n - næste syntaksfejl M-C-b - start af blok M-C-n - slut af blok
  • 8. Udfør JavaScript Jeg bruger spidermonkey: Findes som Debian-pakke Kommandoen er js Se min .emacs Prøv med M-C-x