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.

index.js 376B

123456789101112
  1. 'use strict';
  2. const url = require('url');
  3. const prependHttp = require('prepend-http');
  4. module.exports = (input, options) => {
  5. if (typeof input !== 'string') {
  6. throw new TypeError(`Expected \`url\` to be of type \`string\`, got \`${typeof input}\` instead.`);
  7. }
  8. const finalUrl = prependHttp(input, Object.assign({https: true}, options));
  9. return url.parse(finalUrl);
  10. };