SlideShare a Scribd company logo
Narwhal
 and the Adventures of CommonJS




                                  Clinton R. Nixon
CommonJS
promises  to  be  a  standard  environment  that  
 will  let  JavaScript  code  use  the  same  APIs  
             with  different  interpreters
Why?

JavaScript  is  simple  and  widely-­‐known.
To  succeed,  server-­‐side  JavaScript  must  avoid  
the  fate  of  Lisp.
CommonJS standards
Modules
Packages
System
Binary
Filesystem
Unit  Testing
CommonJS implementations
Narwhal  (Rhino,  v8,  JSC)

Flusspferd  (Spidermonkey/C++)

node.js  (v8;  not  many  standards  or  proposals  implemented)

v8cgi  (v8)

GPSEE  (Spidermonkey/C)

RingoJS  (Rhino;  was  Helma  NG)

Perservere  (Rhino)

SproutCore  (in-­‐browser)
Narwhal
one  of  the  most  mature  CommonJS  implementations
Narwhal
A  CommonJS  platform  or  implementation
Arguably  the  most  mature  implementation
Runs  on  several  interpreters
Rhino  has  the  most  complete  implementation
JavaScriptCore  works  well  on  Macs
Easy  to  add  new  engines  if  you're  a  language  
implementation  hacker
Why?
You  can  use  it  today
Rhino  makes  it  easy  to  build  off  Java  libraries
Lots  of  activity,  and  other  implementations  are  
working  to  be  compatible  with  it
But  still  needs  lots  of  work
Narwhal packages
                                    package.json
Based  on  the  CommonJS            local.json
                                    bin/
package  standard
                                    lib/
tusk  is  a  package  manager           foo.js
                                    src/
sea  is  an  environment  manager   jars/
                                    packages/
Every  project  is  a  package      engines/
                                    tests/
                                        foo.tests.js
package.json
{
        "name":  "jake",
        "author":  "Francisco  Tolmasky  <francisco@280north.com>",
        "contributors":  [
                "Tom  Robinson  (http://tlrobinson.net/)  <tom@280north.com>"
        ],
        "description":  "A  build  system  for  CommonJS,  lifted  from  Rake",
        "keywords":  [
                "build",
                "jake",
                "rake",
                "make"
        ],
        "version":  "0.2.1"
}
Modules
Each  JS  file  under  lib/  is  a  module
Modules  are  executed  within  a  function
Arguments  are  require,  exports,  and  module
Modules  return  exports
Core  concept  of  CommonJS
Module & package
 demonstration
Testing demonstration
Package management
sources.json
{
    "version":  2,
    "includes":  ["http://github.com/280north/narwhal/raw/master/
catalog-­‐2.json"],
    "sources":  {
        "dice":  {
            "type":  "github",
            "user":  "crnixon",
            "name":  "narwhal-­‐dice"
        },
        "caffeine":  {
            "type":  "github",
            "user":  "crnixon",
            "name":  "narwhal-­‐caffeine"
        }
    }
}
Important packages
jack
jake
jsdocs
ejs
nitro
bogart
Real apps I wrote
Questions and discussion


http://narwhaljs.org/
Email  me  at  Clinton  R.  Nixon  <crnixon@gmail.com>
http://pinboard.in/u:crnixon/t:talk:narwhal/

More Related Content

What's hot

Node4J: Running Node.js in a JavaWorld
Node4J: Running Node.js in a JavaWorldNode4J: Running Node.js in a JavaWorld
Node4J: Running Node.js in a JavaWorldIan Bull
 
Running JavaScript Efficiently in a Java World
Running JavaScript Efficiently in a Java WorldRunning JavaScript Efficiently in a Java World
Running JavaScript Efficiently in a Java Worldirbull
 
Jenkins and Groovy
Jenkins and GroovyJenkins and Groovy
Jenkins and GroovyKiyotaka Oku
 
Ionic 2: The Power of TypeScript
Ionic 2:  The Power of TypeScriptIonic 2:  The Power of TypeScript
Ionic 2: The Power of TypeScriptJacob Orshalick
 
Web Applications with Eclipse RT and Docker in the Cloud
Web Applications with Eclipse RT and Docker in the CloudWeb Applications with Eclipse RT and Docker in the Cloud
Web Applications with Eclipse RT and Docker in the CloudMarkus Knauer
 
Docker. Micro services for lazy developers
Docker. Micro services for lazy developersDocker. Micro services for lazy developers
Docker. Micro services for lazy developersEugene Krevenets
 
Kernel Recipes 2016 - Would an ABI changes visualization tool be useful to Li...
Kernel Recipes 2016 - Would an ABI changes visualization tool be useful to Li...Kernel Recipes 2016 - Would an ABI changes visualization tool be useful to Li...
Kernel Recipes 2016 - Would an ABI changes visualization tool be useful to Li...Anne Nicolas
 
An introduction to Node.js application development
An introduction to Node.js application developmentAn introduction to Node.js application development
An introduction to Node.js application developmentshelloidhq
 
Vagrant are you still develop in a non-virtual environment-
Vagrant  are you still develop in a non-virtual environment-Vagrant  are you still develop in a non-virtual environment-
Vagrant are you still develop in a non-virtual environment-Anatoly Bubenkov
 
CoreOS @ summer meetup in Utrecht
CoreOS @ summer meetup in UtrechtCoreOS @ summer meetup in Utrecht
CoreOS @ summer meetup in UtrechtTimo Derstappen
 
Leveraging the Power of containerd Events - Evan Hazlett
Leveraging the Power of containerd Events - Evan HazlettLeveraging the Power of containerd Events - Evan Hazlett
Leveraging the Power of containerd Events - Evan HazlettDocker, Inc.
 
Messaging with the Docker
Messaging with the DockerMessaging with the Docker
Messaging with the DockerHenryk Konsek
 
Getting Started with PureScript
Getting Started with PureScriptGetting Started with PureScript
Getting Started with PureScriptJohn De Goes
 
Containerd: Building a Container Supervisor by Michael Crosby
Containerd: Building a Container Supervisor by Michael CrosbyContainerd: Building a Container Supervisor by Michael Crosby
Containerd: Building a Container Supervisor by Michael CrosbyDocker, Inc.
 
Container Torture: Run any binary, in any container
Container Torture: Run any binary, in any containerContainer Torture: Run any binary, in any container
Container Torture: Run any binary, in any containerDocker, Inc.
 
Devoxx UK 2013: Sandboxing with the Vagrant-Binding API
Devoxx UK 2013: Sandboxing with the Vagrant-Binding APIDevoxx UK 2013: Sandboxing with the Vagrant-Binding API
Devoxx UK 2013: Sandboxing with the Vagrant-Binding APIHendrik Ebbers
 
G rpc lection1
G rpc lection1G rpc lection1
G rpc lection1eleksdev
 

What's hot (20)

Node.js and Ruby
Node.js and RubyNode.js and Ruby
Node.js and Ruby
 
Node4J: Running Node.js in a JavaWorld
Node4J: Running Node.js in a JavaWorldNode4J: Running Node.js in a JavaWorld
Node4J: Running Node.js in a JavaWorld
 
Running JavaScript Efficiently in a Java World
Running JavaScript Efficiently in a Java WorldRunning JavaScript Efficiently in a Java World
Running JavaScript Efficiently in a Java World
 
Jenkins and Groovy
Jenkins and GroovyJenkins and Groovy
Jenkins and Groovy
 
Ionic 2: The Power of TypeScript
Ionic 2:  The Power of TypeScriptIonic 2:  The Power of TypeScript
Ionic 2: The Power of TypeScript
 
Web Applications with Eclipse RT and Docker in the Cloud
Web Applications with Eclipse RT and Docker in the CloudWeb Applications with Eclipse RT and Docker in the Cloud
Web Applications with Eclipse RT and Docker in the Cloud
 
Docker. Micro services for lazy developers
Docker. Micro services for lazy developersDocker. Micro services for lazy developers
Docker. Micro services for lazy developers
 
Nodejs vatsal shah
Nodejs vatsal shahNodejs vatsal shah
Nodejs vatsal shah
 
Kernel Recipes 2016 - Would an ABI changes visualization tool be useful to Li...
Kernel Recipes 2016 - Would an ABI changes visualization tool be useful to Li...Kernel Recipes 2016 - Would an ABI changes visualization tool be useful to Li...
Kernel Recipes 2016 - Would an ABI changes visualization tool be useful to Li...
 
An introduction to Node.js application development
An introduction to Node.js application developmentAn introduction to Node.js application development
An introduction to Node.js application development
 
Vagrant are you still develop in a non-virtual environment-
Vagrant  are you still develop in a non-virtual environment-Vagrant  are you still develop in a non-virtual environment-
Vagrant are you still develop in a non-virtual environment-
 
CoreOS @ summer meetup in Utrecht
CoreOS @ summer meetup in UtrechtCoreOS @ summer meetup in Utrecht
CoreOS @ summer meetup in Utrecht
 
Leveraging the Power of containerd Events - Evan Hazlett
Leveraging the Power of containerd Events - Evan HazlettLeveraging the Power of containerd Events - Evan Hazlett
Leveraging the Power of containerd Events - Evan Hazlett
 
Messaging with the Docker
Messaging with the DockerMessaging with the Docker
Messaging with the Docker
 
Getting Started with PureScript
Getting Started with PureScriptGetting Started with PureScript
Getting Started with PureScript
 
Containerd: Building a Container Supervisor by Michael Crosby
Containerd: Building a Container Supervisor by Michael CrosbyContainerd: Building a Container Supervisor by Michael Crosby
Containerd: Building a Container Supervisor by Michael Crosby
 
Container Torture: Run any binary, in any container
Container Torture: Run any binary, in any containerContainer Torture: Run any binary, in any container
Container Torture: Run any binary, in any container
 
Devoxx UK 2013: Sandboxing with the Vagrant-Binding API
Devoxx UK 2013: Sandboxing with the Vagrant-Binding APIDevoxx UK 2013: Sandboxing with the Vagrant-Binding API
Devoxx UK 2013: Sandboxing with the Vagrant-Binding API
 
G rpc lection1
G rpc lection1G rpc lection1
G rpc lection1
 
Node js
Node jsNode js
Node js
 

Viewers also liked

ОРКСЭ в гимназии
ОРКСЭ  в гимназииОРКСЭ  в гимназии
ОРКСЭ в гимназииTatyana Yakovleva
 
Math online orientation summer 2014
Math online orientation summer 2014Math online orientation summer 2014
Math online orientation summer 2014Anthony Lauer
 
Presentacion carrera sonia1
Presentacion carrera sonia1Presentacion carrera sonia1
Presentacion carrera sonia1sonia carrera
 
brochureConveyance
brochureConveyancebrochureConveyance
brochureConveyanceLina Allaoa
 
Target audienec prezi
Target audienec preziTarget audienec prezi
Target audienec preziMia Jones
 
Don't Turn Traffic Signals Upside Down - Color Accessibility in UI Design
Don't Turn Traffic Signals Upside Down - Color Accessibility in UI DesignDon't Turn Traffic Signals Upside Down - Color Accessibility in UI Design
Don't Turn Traffic Signals Upside Down - Color Accessibility in UI DesignDave Simon
 
Adobe PageMaker 7.0. Oficjalny podręcznik
Adobe PageMaker 7.0. Oficjalny podręcznikAdobe PageMaker 7.0. Oficjalny podręcznik
Adobe PageMaker 7.0. Oficjalny podręcznikWydawnictwo Helion
 
과학과 비과학 이야기: 너 그거 아니?
과학과 비과학 이야기: 너 그거 아니? 과학과 비과학 이야기: 너 그거 아니?
과학과 비과학 이야기: 너 그거 아니? Suntae Kim
 
Earth Day2012 Cash Sponsors
Earth Day2012 Cash SponsorsEarth Day2012 Cash Sponsors
Earth Day2012 Cash SponsorsWarnerAnderson
 
5.ашигт малтмалын хуулинд нэмэлт өөрчлөлт оруулах тухай хууль
5.ашигт малтмалын хуулинд нэмэлт өөрчлөлт оруулах тухай хууль5.ашигт малтмалын хуулинд нэмэлт өөрчлөлт оруулах тухай хууль
5.ашигт малтмалын хуулинд нэмэлт өөрчлөлт оруулах тухай хуульMonatom Mgl
 
О роли предпринимательства в устойчивом развитии регионов России
О роли предпринимательства в устойчивом развитии регионов России   О роли предпринимательства в устойчивом развитии регионов России
О роли предпринимательства в устойчивом развитии регионов России aqua-municipal
 
Dac nhan tam p3ch5
Dac nhan tam p3ch5Dac nhan tam p3ch5
Dac nhan tam p3ch5dinhnam0001
 

Viewers also liked (19)

ОРКСЭ в гимназии
ОРКСЭ  в гимназииОРКСЭ  в гимназии
ОРКСЭ в гимназии
 
здоровье
здоровьездоровье
здоровье
 
Math online orientation summer 2014
Math online orientation summer 2014Math online orientation summer 2014
Math online orientation summer 2014
 
Presentacion carrera sonia1
Presentacion carrera sonia1Presentacion carrera sonia1
Presentacion carrera sonia1
 
brochureConveyance
brochureConveyancebrochureConveyance
brochureConveyance
 
Target audienec prezi
Target audienec preziTarget audienec prezi
Target audienec prezi
 
Remote control
Remote controlRemote control
Remote control
 
DAN
DANDAN
DAN
 
Q6 evaluation
Q6 evaluationQ6 evaluation
Q6 evaluation
 
Don't Turn Traffic Signals Upside Down - Color Accessibility in UI Design
Don't Turn Traffic Signals Upside Down - Color Accessibility in UI DesignDon't Turn Traffic Signals Upside Down - Color Accessibility in UI Design
Don't Turn Traffic Signals Upside Down - Color Accessibility in UI Design
 
Adobe PageMaker 7.0. Oficjalny podręcznik
Adobe PageMaker 7.0. Oficjalny podręcznikAdobe PageMaker 7.0. Oficjalny podręcznik
Adobe PageMaker 7.0. Oficjalny podręcznik
 
과학과 비과학 이야기: 너 그거 아니?
과학과 비과학 이야기: 너 그거 아니? 과학과 비과학 이야기: 너 그거 아니?
과학과 비과학 이야기: 너 그거 아니?
 
Shelbyrae
ShelbyraeShelbyrae
Shelbyrae
 
Earth Day2012 Cash Sponsors
Earth Day2012 Cash SponsorsEarth Day2012 Cash Sponsors
Earth Day2012 Cash Sponsors
 
Fyytfuif
FyytfuifFyytfuif
Fyytfuif
 
5.ашигт малтмалын хуулинд нэмэлт өөрчлөлт оруулах тухай хууль
5.ашигт малтмалын хуулинд нэмэлт өөрчлөлт оруулах тухай хууль5.ашигт малтмалын хуулинд нэмэлт өөрчлөлт оруулах тухай хууль
5.ашигт малтмалын хуулинд нэмэлт өөрчлөлт оруулах тухай хууль
 
О роли предпринимательства в устойчивом развитии регионов России
О роли предпринимательства в устойчивом развитии регионов России   О роли предпринимательства в устойчивом развитии регионов России
О роли предпринимательства в устойчивом развитии регионов России
 
Great pictures
Great pictures Great pictures
Great pictures
 
Dac nhan tam p3ch5
Dac nhan tam p3ch5Dac nhan tam p3ch5
Dac nhan tam p3ch5
 

Similar to Narwhal and the Adventures of CommonJS

Overview of Node JS
Overview of Node JSOverview of Node JS
Overview of Node JSJacob Nelson
 
Building Server Applications Using ObjectiveC And GNUstep
Building Server Applications Using ObjectiveC And GNUstepBuilding Server Applications Using ObjectiveC And GNUstep
Building Server Applications Using ObjectiveC And GNUstepguest9efd1a1
 
Building Server Applications Using Objective C And Gn Ustep
Building Server Applications Using Objective C And Gn UstepBuilding Server Applications Using Objective C And Gn Ustep
Building Server Applications Using Objective C And Gn Ustepwangii
 
I Just Want to Run My Code: Waypoint, Nomad, and Other Things
I Just Want to Run My Code: Waypoint, Nomad, and Other ThingsI Just Want to Run My Code: Waypoint, Nomad, and Other Things
I Just Want to Run My Code: Waypoint, Nomad, and Other ThingsMichael Lange
 
Docker module 1
Docker module 1Docker module 1
Docker module 1Liang Bo
 
Dcjq node.js presentation
Dcjq node.js presentationDcjq node.js presentation
Dcjq node.js presentationasync_io
 
Nodejs a-practical-introduction-oredev
Nodejs a-practical-introduction-oredevNodejs a-practical-introduction-oredev
Nodejs a-practical-introduction-oredevFelix Geisendörfer
 
Unikernels - Bristech June 2016
Unikernels - Bristech June 2016 Unikernels - Bristech June 2016
Unikernels - Bristech June 2016 Daniel Drozdzewski
 
TorqueBox: The beauty of Ruby with the power of JBoss. Presented at Devnexus...
TorqueBox: The beauty of Ruby with the power of JBoss.  Presented at Devnexus...TorqueBox: The beauty of Ruby with the power of JBoss.  Presented at Devnexus...
TorqueBox: The beauty of Ruby with the power of JBoss. Presented at Devnexus...bobmcwhirter
 
Introduction to node.js By Ahmed Assaf
Introduction to node.js  By Ahmed AssafIntroduction to node.js  By Ahmed Assaf
Introduction to node.js By Ahmed AssafAhmed Assaf
 
RubyStack: the easiest way to deploy Ruby on Rails
RubyStack: the easiest way to deploy Ruby on RailsRubyStack: the easiest way to deploy Ruby on Rails
RubyStack: the easiest way to deploy Ruby on Railselliando dias
 
LibOS as a regression test framework for Linux networking #netdev1.1
LibOS as a regression test framework for Linux networking #netdev1.1LibOS as a regression test framework for Linux networking #netdev1.1
LibOS as a regression test framework for Linux networking #netdev1.1Hajime Tazaki
 
Why everyone is excited about Docker (and you should too...) - Carlo Bonamic...
Why everyone is excited about Docker (and you should too...) -  Carlo Bonamic...Why everyone is excited about Docker (and you should too...) -  Carlo Bonamic...
Why everyone is excited about Docker (and you should too...) - Carlo Bonamic...Codemotion
 
Dockerizing a Symfony2 application
Dockerizing a Symfony2 applicationDockerizing a Symfony2 application
Dockerizing a Symfony2 applicationRoman Rodomansky
 
codemotion-docker-2014
codemotion-docker-2014codemotion-docker-2014
codemotion-docker-2014Carlo Bonamico
 
Iz Pack
Iz PackIz Pack
Iz PackInria
 
PHP Dependency Management with Composer
PHP Dependency Management with ComposerPHP Dependency Management with Composer
PHP Dependency Management with ComposerAdam Englander
 
Parallelizing CI using Docker Swarm-Mode
Parallelizing CI using Docker Swarm-ModeParallelizing CI using Docker Swarm-Mode
Parallelizing CI using Docker Swarm-ModeAkihiro Suda
 

Similar to Narwhal and the Adventures of CommonJS (20)

Overview of Node JS
Overview of Node JSOverview of Node JS
Overview of Node JS
 
Building Server Applications Using ObjectiveC And GNUstep
Building Server Applications Using ObjectiveC And GNUstepBuilding Server Applications Using ObjectiveC And GNUstep
Building Server Applications Using ObjectiveC And GNUstep
 
Building Server Applications Using Objective C And Gn Ustep
Building Server Applications Using Objective C And Gn UstepBuilding Server Applications Using Objective C And Gn Ustep
Building Server Applications Using Objective C And Gn Ustep
 
I Just Want to Run My Code: Waypoint, Nomad, and Other Things
I Just Want to Run My Code: Waypoint, Nomad, and Other ThingsI Just Want to Run My Code: Waypoint, Nomad, and Other Things
I Just Want to Run My Code: Waypoint, Nomad, and Other Things
 
Docker module 1
Docker module 1Docker module 1
Docker module 1
 
Dcjq node.js presentation
Dcjq node.js presentationDcjq node.js presentation
Dcjq node.js presentation
 
Nodejs a-practical-introduction-oredev
Nodejs a-practical-introduction-oredevNodejs a-practical-introduction-oredev
Nodejs a-practical-introduction-oredev
 
Play framework
Play frameworkPlay framework
Play framework
 
Unikernels - Bristech June 2016
Unikernels - Bristech June 2016 Unikernels - Bristech June 2016
Unikernels - Bristech June 2016
 
TorqueBox: The beauty of Ruby with the power of JBoss. Presented at Devnexus...
TorqueBox: The beauty of Ruby with the power of JBoss.  Presented at Devnexus...TorqueBox: The beauty of Ruby with the power of JBoss.  Presented at Devnexus...
TorqueBox: The beauty of Ruby with the power of JBoss. Presented at Devnexus...
 
Introduction to node.js By Ahmed Assaf
Introduction to node.js  By Ahmed AssafIntroduction to node.js  By Ahmed Assaf
Introduction to node.js By Ahmed Assaf
 
RubyStack: the easiest way to deploy Ruby on Rails
RubyStack: the easiest way to deploy Ruby on RailsRubyStack: the easiest way to deploy Ruby on Rails
RubyStack: the easiest way to deploy Ruby on Rails
 
LibOS as a regression test framework for Linux networking #netdev1.1
LibOS as a regression test framework for Linux networking #netdev1.1LibOS as a regression test framework for Linux networking #netdev1.1
LibOS as a regression test framework for Linux networking #netdev1.1
 
Why everyone is excited about Docker (and you should too...) - Carlo Bonamic...
Why everyone is excited about Docker (and you should too...) -  Carlo Bonamic...Why everyone is excited about Docker (and you should too...) -  Carlo Bonamic...
Why everyone is excited about Docker (and you should too...) - Carlo Bonamic...
 
Dockerizing a Symfony2 application
Dockerizing a Symfony2 applicationDockerizing a Symfony2 application
Dockerizing a Symfony2 application
 
codemotion-docker-2014
codemotion-docker-2014codemotion-docker-2014
codemotion-docker-2014
 
Iz Pack
Iz PackIz Pack
Iz Pack
 
PHP Dependency Management with Composer
PHP Dependency Management with ComposerPHP Dependency Management with Composer
PHP Dependency Management with Composer
 
Docker-v3.pdf
Docker-v3.pdfDocker-v3.pdf
Docker-v3.pdf
 
Parallelizing CI using Docker Swarm-Mode
Parallelizing CI using Docker Swarm-ModeParallelizing CI using Docker Swarm-Mode
Parallelizing CI using Docker Swarm-Mode
 

More from Clinton Dreisbach

More from Clinton Dreisbach (7)

Migrating Legacy Rails Apps to Rails 3
Migrating Legacy Rails Apps to Rails 3Migrating Legacy Rails Apps to Rails 3
Migrating Legacy Rails Apps to Rails 3
 
Having Fun with Play
Having Fun with PlayHaving Fun with Play
Having Fun with Play
 
HTML5 Now
HTML5 NowHTML5 Now
HTML5 Now
 
Unearthed Arcana for Web People
Unearthed Arcana for Web PeopleUnearthed Arcana for Web People
Unearthed Arcana for Web People
 
The Joy Of Ruby
The Joy Of RubyThe Joy Of Ruby
The Joy Of Ruby
 
Advanced Internationalization with Rails
Advanced Internationalization with RailsAdvanced Internationalization with Rails
Advanced Internationalization with Rails
 
Dealing with Legacy PHP Applications
Dealing with Legacy PHP ApplicationsDealing with Legacy PHP Applications
Dealing with Legacy PHP Applications
 

Recently uploaded

SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...CzechDreamin
 
Optimizing NoSQL Performance Through Observability
Optimizing NoSQL Performance Through ObservabilityOptimizing NoSQL Performance Through Observability
Optimizing NoSQL Performance Through ObservabilityScyllaDB
 
Introduction to Open Source RAG and RAG Evaluation
Introduction to Open Source RAG and RAG EvaluationIntroduction to Open Source RAG and RAG Evaluation
Introduction to Open Source RAG and RAG EvaluationZilliz
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Product School
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...Product School
 
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...Product School
 
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomSalesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomCzechDreamin
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...UiPathCommunity
 
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptxIOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptxAbida Shariff
 
AI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří KarpíšekAI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří KarpíšekCzechDreamin
 
Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Alison B. Lowndes
 
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Product School
 
JMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and GrafanaJMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and GrafanaRTTS
 
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)Julian Hyde
 
Search and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical FuturesSearch and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical FuturesBhaskar Mitra
 
Demystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John StaveleyDemystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John StaveleyJohn Staveley
 
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...CzechDreamin
 
UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3DianaGray10
 
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...Product School
 
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptxUnpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptxDavid Michel
 

Recently uploaded (20)

SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
 
Optimizing NoSQL Performance Through Observability
Optimizing NoSQL Performance Through ObservabilityOptimizing NoSQL Performance Through Observability
Optimizing NoSQL Performance Through Observability
 
Introduction to Open Source RAG and RAG Evaluation
Introduction to Open Source RAG and RAG EvaluationIntroduction to Open Source RAG and RAG Evaluation
Introduction to Open Source RAG and RAG Evaluation
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
 
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
From Siloed Products to Connected Ecosystem: Building a Sustainable and Scala...
 
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomSalesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
 
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptxIOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
 
AI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří KarpíšekAI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří Karpíšek
 
Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........
 
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
 
JMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and GrafanaJMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and Grafana
 
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
 
Search and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical FuturesSearch and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical Futures
 
Demystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John StaveleyDemystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John Staveley
 
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
 
UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3UiPath Test Automation using UiPath Test Suite series, part 3
UiPath Test Automation using UiPath Test Suite series, part 3
 
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
 
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptxUnpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
Unpacking Value Delivery - Agile Oxford Meetup - May 2024.pptx
 

Narwhal and the Adventures of CommonJS

  • 1. Narwhal and the Adventures of CommonJS Clinton R. Nixon
  • 2. CommonJS promises  to  be  a  standard  environment  that   will  let  JavaScript  code  use  the  same  APIs   with  different  interpreters
  • 3. Why? JavaScript  is  simple  and  widely-­‐known. To  succeed,  server-­‐side  JavaScript  must  avoid   the  fate  of  Lisp.
  • 5. CommonJS implementations Narwhal  (Rhino,  v8,  JSC) Flusspferd  (Spidermonkey/C++) node.js  (v8;  not  many  standards  or  proposals  implemented) v8cgi  (v8) GPSEE  (Spidermonkey/C) RingoJS  (Rhino;  was  Helma  NG) Perservere  (Rhino) SproutCore  (in-­‐browser)
  • 6. Narwhal one  of  the  most  mature  CommonJS  implementations
  • 7. Narwhal A  CommonJS  platform  or  implementation Arguably  the  most  mature  implementation Runs  on  several  interpreters Rhino  has  the  most  complete  implementation JavaScriptCore  works  well  on  Macs Easy  to  add  new  engines  if  you're  a  language   implementation  hacker
  • 8. Why? You  can  use  it  today Rhino  makes  it  easy  to  build  off  Java  libraries Lots  of  activity,  and  other  implementations  are   working  to  be  compatible  with  it But  still  needs  lots  of  work
  • 9. Narwhal packages package.json Based  on  the  CommonJS   local.json bin/ package  standard lib/ tusk  is  a  package  manager    foo.js src/ sea  is  an  environment  manager jars/ packages/ Every  project  is  a  package engines/ tests/    foo.tests.js
  • 10. package.json {        "name":  "jake",        "author":  "Francisco  Tolmasky  <francisco@280north.com>",        "contributors":  [                "Tom  Robinson  (http://tlrobinson.net/)  <tom@280north.com>"        ],        "description":  "A  build  system  for  CommonJS,  lifted  from  Rake",        "keywords":  [                "build",                "jake",                "rake",                "make"        ],        "version":  "0.2.1" }
  • 11. Modules Each  JS  file  under  lib/  is  a  module Modules  are  executed  within  a  function Arguments  are  require,  exports,  and  module Modules  return  exports Core  concept  of  CommonJS
  • 12. Module & package demonstration
  • 13.
  • 15.
  • 17. sources.json {    "version":  2,    "includes":  ["http://github.com/280north/narwhal/raw/master/ catalog-­‐2.json"],    "sources":  {        "dice":  {            "type":  "github",            "user":  "crnixon",            "name":  "narwhal-­‐dice"        },        "caffeine":  {            "type":  "github",            "user":  "crnixon",            "name":  "narwhal-­‐caffeine"        }    } }
  • 19. Real apps I wrote
  • 20. Questions and discussion http://narwhaljs.org/ Email  me  at  Clinton  R.  Nixon  <crnixon@gmail.com> http://pinboard.in/u:crnixon/t:talk:narwhal/