How to use the meta.id function in meta

To help you get started, weā€™ve selected a few meta examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github metarhia / server / applications / metarhia.com / static / js / console.js View on Github external
ajax.pair(pairData, (err, data) => {
              if (data.result === 'wait') {
                print('Incorrect pairing code');
                commandLoop();
              } else if (data.result === 'correct') {
                localStorage['meta.id'] = data.id;
                print('Devices paired');
                commandLoop();
              }
            });
          }, 30000);
github metarhia / server / applications / metarhia.com / static / js / console.js View on Github external
function initStorage() {
  if (!window.localStorage) {
    print('Local storage is not available.<br>Unsupported device.');
  } else {
    if (localStorage['meta.ver']) {
      localStorage['meta.ver'] = METARHIA_VERSION;
      const lastActivity = new Date(parseInt(localStorage['meta.last'], 10));
      print(
        'Local storage found<br>Last activity: ' + lastActivity.toUTCString()
      );
      if (localStorage['meta.id']) {
        //print('System ready');
      } else {
        localStorage['meta.id'] = generateUnique();
        print('New id generated');
      }
    } else {
      print('Local storage initialization...');
      localStorage['meta.ver'] = METARHIA_VERSION;
      localStorage['meta.id'] = generateUnique();
      print('New id generated');
      enterKey();
    }
    localStorage['meta.last'] = (new Date()).getTime();
  }
}
github metarhia / server / applications / metarhia.com / static / js / console.js View on Github external
function initStorage() {
  if (!window.localStorage) {
    print('Local storage is not available.<br>Unsupported device.');
  } else {
    if (localStorage['meta.ver']) {
      localStorage['meta.ver'] = METARHIA_VERSION;
      const lastActivity = new Date(parseInt(localStorage['meta.last'], 10));
      print(
        'Local storage found<br>Last activity: ' + lastActivity.toUTCString()
      );
      if (localStorage['meta.id']) {
        //print('System ready');
      } else {
        localStorage['meta.id'] = generateUnique();
        print('New id generated');
      }
    } else {
      print('Local storage initialization...');
      localStorage['meta.ver'] = METARHIA_VERSION;
      localStorage['meta.id'] = generateUnique();
      print('New id generated');
      enterKey();
    }
    localStorage['meta.last'] = (new Date()).getTime();
  }
}
github metarhia / server / applications / metarhia.com / static / js / console.js View on Github external
who() {
    print('id: ' + localStorage['meta.id']);
    commandLoop();
  },
  info() {
github metarhia / server / applications / metarhia.com / static / js / console.js View on Github external
setTimeout(() => {
            const pairData = {
              local: pairingCode,
              remote: pcode,
              id: localStorage['meta.id']
            };
            ajax.pair(pairData, (err, data) => {
              if (data.result === 'wait') {
                print('Incorrect pairing code');
                commandLoop();
              } else if (data.result === 'correct') {
                localStorage['meta.id'] = data.id;
                print('Devices paired');
                commandLoop();
              }
            });
          }, 30000);
        } else if (data.result === 'correct') {

meta

tool for turning many repos into a meta repo. why choose many repos or a monolithic repo, when you can have both with a meta repo?

MIT
Latest version published 3 years ago

Package Health Score

53 / 100
Full package analysis