Giter Site home page Giter Site logo

node-process-lab-g-416's Introduction

Access Global and Process Variables Lab

In this lab, you'll need to demonstrate how to access global and process variables.

Objectives

  1. Write a script that accesses global object
  2. Add logic to access process info
  3. Save and run the scripts

Introduction

You are a DevOps engineer and you're tasked with deploying a Node.js API server. Developers worked months on this app and now team needs your expertise to push the app to production.

The server needs to be "smart" enough to get secret values from whatever OS or environment it on. In other words, this lab will test you how good you know and utilize process information. For example, global have other global objects like process, while global.process or just process have system information.

Instructions

  1. Create a script version.js which returns the current node version. Export with module.exports = function(){...}
  2. Create a script envvar.js which returns NODE_ENV environment variable. Export with module.exports = function(){...}
  3. Create a script platform.js which returns the platform name on which you are running it. Export with module.exports = function(){...}
  4. Run npm test to verify your 3 solutions

Extra Info

View node-process-lab on Learn.co and start learning to code for free.

node-process-lab-g-416's People

Contributors

azat-co avatar victhevenot avatar smendoza787 avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.