class: center, middle # Node.js Modules Dependency managment & `npm`. --- # Node.js Layers --- # Node.js Layers **2 Layers:** - Core - Userland --- # Node.js Layers **~~2~~ Layers:** - Core - Userland --- # Node.js Layers **3 Layers:** - **Core** - *Userland:* - - --- # Node.js Layers **3 Layers:** - **Core** - *Userland:* - **Packages** - --- # Node.js Layers **3 Layers:** - **Core** - *Userland:* - **Packages** - **Application Code** --- # Node.js Core --- # Node.js Core **Core is small:** --- # Node.js Core **Core is small:** - C/C++ V8 Bindings --- # Node.js Core **Core is small:** - C/C++ V8 Bindings - JavaScript APIs --- # Node.js Core **Core is small:** - C/C++ V8 Bindings - JavaScript APIs - Module System --- # Node.js Core **Core is small:** - C/C++ V8 Bindings - JavaScript APIs - Module System - Event-loop --- # Node.js Core **Core is low-level:** --- # Node.js Core **Core is low-level:** > *"If it can be done in Userland, it belongs in Userland."* --- # Node.js Core **Core is low-level:** > *"If it can be done in Userland, it belongs in Userland."* - No Web Framework --- # Node.js Core **Core is low-level:** > *"If it can be done in Userland, it belongs in Userland."* - No Web Framework - No Convenience Utilities --- # Node.js Core **Core is low-level:** > *"If it can be done in Userland, it belongs in Userland."* - No Web Framework - No Convenience Utilities - No Standard Library --- # Node.js Core **Core is low-level:** > *"If it can be done in Userland, it belongs in Userland."* - No Web Framework - No Convenience Utilities - No Standard Library - No Database Drivers --- # Node.js Core **Core Modules:** --- # Node.js Core **Core Modules:** - Common: `buffer` · `events` · `fs` · `http` · `https` · `net` · `os`
`path` · `querystring` · `stream` · `url` · `util` --- # Node.js Core **Core Modules:** - Common: `buffer` · `events` · `fs` · `http` · `https` · `net` · `os`
`path` · `querystring` · `stream` · `url` · `util` - Advanced: `child_process` · `cluster` · `crypto` · `dns` · `punycode`
`readline` · `repl` · `tls` · `tty` · `v8` · `vm` · `zlib` --- # Node.js Core **Core Modules:** - Common: `buffer` · `events` · `fs` · `http` · `https` · `net` · `os`
`path` · `querystring` · `stream` · `url` · `util` - Advanced: `child_process` · `cluster` · `crypto` · `dns` · `punycode`
`readline` · `repl` · `tls` · `tty` · `v8` · `vm` · `zlib` - *Probably* Never: `assert` · `console` · `constants` · `dgram` · `domain`
`module` · `process` · `string_decoder` · `timers` --- class: center, middle # Questions?