lanterna
v1.0.15
Published
Google Slides presentation scraper
Maintainers
Readme
Lanterna
Table of contents
Idea and motivation
Published or embedded Google Slides presentations are really hard (or even impossible) to download in an easy manner. That's exactly Lanterna's main purpose - to facilitate the process of downloading published or embedded presentations. It works as follows:
- full-page screenshots of the provided presentation are taken;
- the user may choose to save them as separate .pdf files or merge them into one .pdf file;
- optionally, the user may choose to enable OCR scanning of the presentation, making the output .pdf file(s) searchable
Installing
NPM module
npm install lanternaThis assumes you're using npm as your package manager.
Local setup and tests
In order to work on Lanterna, please ensure you have installed the following:
- Node.js provides the runtime needed to run this project. (Installation instructions - need
v20.0.0or greater). - NPM is the package manager used for this project. (Installation instructions need
v11.12.1or greater). - Git is the SCM used for this project. (Installation instructions
After doing that, you'll have to clone the project:
git clone https://github.com/tkostadinov004/lanterna.git
cd lanternaAfter cloning the project, you have to install the dependencies (they are managed within the package.json file), so all you have to do is to run:
npm installIf you don't see any errors or warnings, then everything should have worked correctly. The next thing would be to run the unit tests in order to verify that everything is working correctly.
Unit Tests
We use Jest to write unit tests for Lanterna. All unit tests are kept in the tests directory.
To run the unit tests, execute the following:
npm testThe output would look something like this:
npm test
> [email protected] test
> jest
PASS tests/ocr/ocr.test.ts
PASS tests/scrape/scrape.test.ts
Test Suites: 2 passed, 2 total
Tests: 7 passed, 7 total
Snapshots: 0 total
Time: 3.826 s
Ran all test suites.Hopefully you see that all the tests passed! But if you see errors or warnings, then something must be wrong with your setup. Please ensure you've following the installation steps outlined in the local setup and tests section.
