All Projects → abhinaba-ghosh → any-text

abhinaba-ghosh / any-text

Licence: MIT License
Get text content from any file

Programming Languages

javascript
184084 projects - #8 most used programming language
HTML
75241 projects

Projects that are alternatives of or similar to any-text

Fltrdr
A TUI text reader for the terminal.
Stars: ✭ 477 (+2410.53%)
Mutual labels:  text, reader
Nlp
[UNMANTEINED] Extract values from strings and fill your structs with nlp.
Stars: ✭ 367 (+1831.58%)
Mutual labels:  text, text-extraction
barcode scan2
[reborned barcode_scan] A flutter plugin for reading 2D barcodes and QR codes.
Stars: ✭ 43 (+126.32%)
Mutual labels:  reader
vue-resize-text
A vue directive which automatically resize font size based on element width.
Stars: ✭ 65 (+242.11%)
Mutual labels:  text
split
A string split function and iterator for Lua
Stars: ✭ 15 (-21.05%)
Mutual labels:  text
TextInputLayout
The objective of this code is to guide you to create login screen with TextInputLayout in iOS app.
Stars: ✭ 30 (+57.89%)
Mutual labels:  text
iwata-asks-downloader
Tool to download Iwata Asks interviews (none of which are stored in this repo)
Stars: ✭ 17 (-10.53%)
Mutual labels:  text
BCF-js
bcf-js is a BIM Collaboration Format (BCF) reader & parser developed and maintained by Parametricos Ltd.
Stars: ✭ 18 (-5.26%)
Mutual labels:  reader
react-native-input-bar
Fully customizable, beautifully designed Input Bar for React Native
Stars: ✭ 32 (+68.42%)
Mutual labels:  text
cherche
📑 Neural Search
Stars: ✭ 196 (+931.58%)
Mutual labels:  reader
glfont
A modern opengl text rending library for Golang
Stars: ✭ 27 (+42.11%)
Mutual labels:  text
ss-search
The most basic, yet powerful text search.
Stars: ✭ 41 (+115.79%)
Mutual labels:  text
markdown-utils
Convert plain text into snippets of markdown.
Stars: ✭ 28 (+47.37%)
Mutual labels:  text
text2class
Multi-class text categorization using state-of-the-art pre-trained contextualized language models, e.g. BERT
Stars: ✭ 15 (-21.05%)
Mutual labels:  text
pytextcodifier
📦 Turn your text files into codified images or your codified images into text files.
Stars: ✭ 14 (-26.32%)
Mutual labels:  text
react-text-translator
An experimental way to translate text inside React components with context
Stars: ✭ 15 (-21.05%)
Mutual labels:  text
texthighlighter
a no dependency typescript npm package for highlighting user selected text
Stars: ✭ 17 (-10.53%)
Mutual labels:  text
WeYue-wxapp
微Yue电子书阅读-微信小程序
Stars: ✭ 47 (+147.37%)
Mutual labels:  reader
eBookReaderNX
A Nintendo Switch eBook Reader
Stars: ✭ 15 (-21.05%)
Mutual labels:  reader
KoHighlights
KOHighlights is a utility for viewing KOReader's highlights and/or export them to simple text, csv or html files.
Stars: ✭ 62 (+226.32%)
Mutual labels:  reader

Any-Text

Extract text content from a file.

Supported File Extensions

  • DOC
  • DOCX
  • DOT
  • PDF
  • CSV
  • TXT
  • XLS
  • XLSX

How to use

  • Install the library as a dependency (/dev-dependency)
npm i -D any-text
  • Make use of the getText method to read the text content
var reader = require('any-text');

reader.getText(`path-to-file`)
  .then(function (data) {
    console.log(data); // handle success
  })
  .catch(function (error) {
    console.log(error); // handle error
  });
  • You can also use the async/await notation
var reader = require('any-text');

const text = await reader.getText(`path-to-file`);

console.log(text);

Sample Test

var reader = require('any-text');

const chai = require('chai');
const expect = chai.expect;

describe('file reader checks', () => {
  it('check docx file content', async () => {
    expect(
      await reader.getText(`${process.cwd()}/test/files/dummy.docx`)
    ).to.contains('Lorem ipsum');
  });
});

Tell me your issues

you can raise any issue here

Contribution

Any pull request is welcome.

If it works for you , give a Star!

- Copyright © 2020- Abhinaba Ghosh

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].