Software zum Installieren eines Smart-Mirror Frameworks , zum Nutzen von hochschulrelevanten Informationen, auf einem Raspberry-Pi.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

isOnlyWhitespace.js 428B

12345678910111213141516171819202122
  1. 'use strict';
  2. const isWhitespace = require('./isWhitespace');
  3. /**
  4. * Returns a Boolean indicating whether the the input string is only whitespace.
  5. *
  6. * @param {string} input
  7. * @returns {boolean}
  8. */
  9. module.exports = function (input) {
  10. let isOnlyWhitespace = true;
  11. for (let i = 0, l = input.length; i < l; i++) {
  12. if (!isWhitespace(input[i])) {
  13. isOnlyWhitespace = false;
  14. break;
  15. }
  16. }
  17. return isOnlyWhitespace;
  18. };