[nijmegenjs] node.js - 2014/04/25

Post on 21-Jun-2015

222 Views

Category:

Internet

6 Downloads

Preview:

Click to see full reader

DESCRIPTION

About mixins, proxies and identifiers in Node.js

TRANSCRIPT

Agenda

● Introduction● Creating a framework● [code] Mixins / Proxies● [code] Identifers● [code] Component example

Me

● Joep van der He ijden● 24 years old● Graduated 2012

Software EngineeringFontys University

● Work:

● Java (Android)● Javascript (Angular.js,

Node.js, others stuf)● PHP (Joom la/Nooku)

https://g ithub .com /K laasvaak

Creating a frameworkWhy?

Everyone should (try to) make a framework (or contribute)

Missing the magic in existing frameworks

Creating a frameworkWhat should it do?

Provide an environment for Rapid Application Development

Creating a frameworkWhat do others do?

● MVC● ORM● Router (but you have to write your own routes)

● Hooks

Creating a frameworkWhat to do?

● MVC● ORM● Router (without having to write your own routes)

● Hooks● Component driven● Stimulate reuse of code (mixins)

● Magic!● JWT (https://tools.ietf.org/html/draft-jones-json-web-token-10)

Mixins / Proxies

Code

Identifers

[scheme]://[authority]/[package].[path].[name]

Example:com://site/customers.controller.customer

Identifers

Get Objects by identifer with fallbacks

Example:com://site/customers.controller.customer

Result: BaseController or CustomerController

Identifers

Code

What's next

● First: stable v1 release with examples● Look at ecmascript 6 features● Future: succes ? continue : rewrite for express

top related