What is Universal JavaScript?

May 10, 2017

“Universal JavaScript” is used to describe JavaScript code that “can execute on the client and the server”.

References

  • https://medium.com/@mjackson/universal-javascript-4761051b7ae9
Categories : JavaScript

What is semantic commit message?

May 9, 2017

Semantic commit message is a commit message format which helps to write better commit message.

References

  • http://stackoverflow.com/questions/26944762/when-to-use-chore-as-type-of-commit-message
  • https://seesparkbox.com/foundry/semantic_commit_messages
  • https://github.com/fteem/git-semantic-commits
Categories : Programming

What is software regression?

May 5, 2017

A software regression is a software bug which makes a feature to stop functioning as intended after a certain event, for example a system upgrade, system patching.

One approach to avoiding this kind of problem is regression testing.

References

  • https://en.wikipedia.org/wiki/Software_regression
  • https://en.wikipedia.org/wiki/Regression_testing
  • http://stackoverflow.com/questions/3464629/what-does-regression-test-mean
Categories : Programming

What are Higher Order Function in JavaScript

May 4, 2017

Functions that operate on other functions, either by taking them as arguments or by returing them, are called higher order functions.

function expression(name) {
    return function() {
        console.log(name);
    }
}

let smile = expression('smile');
let laugh = expression('laugh');

smile(); // prints 'smile'
laugh(); // prints 'laugh'

References

Categories : JavaScript

What is NODE_ENV in Node.js

May 3, 2017

NODE_ENV is an environment variable made popular by the Express.js framework. It is specifically used to state whethere a particular environment is production or development.

var environment = process.env.NODE_ENV

References

  • http://stackoverflow.com/questions/16978256/what-is-node-env-in-express
Categories : JavaScript   NodeJS