Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Progressive Nest

Progressive Nest

Progressive Node.js Framework with Nest

1a73ecdb082f212bf8d81eb9a3a53e29?s=128

Jecelyn Yeen

October 18, 2018
Tweet

Transcript

  1. nest | progressive node.js framework | scalable +

  2. @JecelynYeen From Kuala Lumpur, Malaysia • GDE - Web technologies,

    Angular • Software Architect @ Randstad Organizer:
  3. • node is good, but… • nest is here to…

    • nest core concepts - live coding +
  4. Story of building LEGO house

  5. simple, intuitive, easy to start

  6. structure, details, layout

  7. None
  8. - Design & Plan - Modular - Ecosystem

  9. Software Development with

  10. JavaScript runtime that built on top of Google Chrome’s V8

    engine.
  11. is simple… - Setup time: 1 minute - Code: 2

    lines
  12. const app = require('express')(); app.listen(3000);

  13. const app = require('express')(); app.get('/', (req, res) => res.send('hello, simple

    house!’)); app.listen(3000);
  14. Why ? Language Reusability Productivity Community

  15. Simplicity Wait, what is the definition of simple?

  16. is simple up to a certain point When build medium

    - large applications, the definition of simple change.
  17. Application Issues (Medium to Large) Lack of common architecture Fragile

    execution Problematic growth Structure Robustness Scalability
  18. “We build our computer (systems) the way we build our

    cities. Over time, without a plan, on top of ruins.” - Ellen Ullman
  19. None
  20. Why ? Application Architecture Dependency Injection Middleware Structure Platform Agnostic

  21. $ npm install -g @nestjs/cli $ nest new lego-house CREATE

    /lego-house/.prettierrc (51 bytes) CREATE /lego-house/README.md (339 bytes) CREATE /lego-house/nodemon.json (147 bytes) CREATE /lego-house/package.json (1633 bytes) CREATE /lego-house/src/app.controller.spec.ts (639 bytes) CREATE /lego-house/src/app.controller.ts (266 bytes) CREATE /lego-house/src/app.module.ts (250 bytes) CREATE /lego-house/src/app.service.ts (138 bytes) CREATE /lego-house/src/main.hmr.ts (329 bytes) CREATE /lego-house/src/main.ts (208 bytes) CREATE /lego-house/test/app.e2e-spec.ts (593 bytes) CREATE /lego-house/test/jest-e2e.json (154 bytes) CREATE /lego-house/tsconfig.json (477 bytes) CREATE /lego-house/tslint.json (895 bytes) CREATE /lego-house/webpack.config.js (695 bytes) Naming
  22. lego-house npm start

  23. What’s (the good stuffs) in the project? Typescript Jest Nest

  24. Core concepts Controllers Providers Modules Middleware Exception filters Pipes Guards

    Interceptors https://docs.nestjs.com/first-steps Controllers Providers Modules Middleware
  25. Let’s code!

  26. Platform Agnostic GraphQL Microservices Web Sockets Building apps with several

    transport layers & contexts
  27. is Low entry threshold Fully featured Open source Compatibility

  28. “It’s never on how difficult is to write bad code,

    it’s on how easy is to write good code.”
  29. https://speakerdeck.com/chybie/progressive-nest +

  30. References: @kammysliwiec - https://speakerdeck.com/kamilmysliwiec/rethinking- enterprise-architectures-with-node-dot-js @Rafael_Casuso - https://www.slideshare.net/RafaelCasusoRomate/ solid-nodejs-with-typescript-jest-nestjs