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
npm install lanterna
This assumes you're using npm as your package manager.
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 -
v20.0.0or greater is needed). - NPM is the package manager used for this project. (Installation instructions -
v11.12.1or greater is needed). - 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 lanterna
After 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 install
If 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.
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 test
The output would look something like this:
npm test
> lanterna@1.0.0 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.