How to use text-extensions - 1 common examples

To help you get started, we’ve selected a few text-extensions 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 jMavarez / Tana / src / js / main / dialog.js View on Github external
function getTypeByExtention(path) {
  let type = 'none';
  let ext = path.slice((path.lastIndexOf(".") + 1));

  if (textExtensions.includes(ext)) {
    type = 'text';
  } else if (imageExt.includes(ext)) {
    type = 'image';
  } else if (videoExtensions.includes(ext)) {
    type = 'video';
  }

  return type;
}

text-extensions

List of text file extensions

MIT
Latest version published 3 years ago

Package Health Score

70 / 100
Full package analysis

Popular text-extensions functions