![PyPI Now Supports iOS and Android Wheels for Mobile Python Development](https://cdn.sanity.io/images/cgdhsj6q/production/96416c872705517a6a65ad9646ce3e7caef623a0-1024x1024.webp?w=400&fit=max&auto=format)
Security News
PyPI Now Supports iOS and Android Wheels for Mobile Python Development
PyPI now supports iOS and Android wheels, making it easier for Python developers to distribute mobile packages.
@flipbookqr/reader
Advanced tools
The Flipbook reader is responsible for reading "flipbooks" created by the [Flipbook writer](https://github.com/cereallarceny/flipbook/tree/main/packages/writer). It can be used to decode a series of QR codes into a single payload.
The Flipbook reader is responsible for reading "flipbooks" created by the Flipbook writer. It can be used to decode a series of QR codes into a single payload.
NPM:
npm install @flipbookqr/reader
Yarn:
yarn add @flipbookqr/reader
PNPM:
pnpm add @flipbookqr/reader
Bun:
bun add @flipbookqr/reader
The following will read a QR code via the getDisplayMedia
(screenshare) API:
import { Reader } from '@flipbookqr/reader';
// Create a new instance of the Flipbook reader
const reader = new Reader(optionalConfig);
// Read the Flipbook visible on the screen
const result = await reader.read();
The result
is a is the original payload that was encoded into the series of QR codes.
The following will read a QR code via the getUserMedia
(camera) API:
import { Reader, WebRTCProcessor } from '@flipbookqr/reader';
// Create a new instance of the Flipbook reader
const reader = new Reader({
frameProcessor: new WebRTCProcessor('camera'),
});
// Get a list of all available camera sources
const sources = await reader.opts.frameProcessor.getStreamTracks();
// Select a camera source
reader.opts.frameProcessor.setStreamTrack(sources[0]);
// Note: If you don't do the above two commands, it will default to the first camera source
// Read the Flipbook visible on the screen
const result = await reader.read();
The result
is a is the original payload that was encoded into the series of QR codes.
The following will read a QR code from a file:
import { Reader, FileProcessor } from '@flipbookqr/reader';
const file = new File(); // some file
const reader = new Reader({
frameProcessor: new FileProcessor(),
});
const result = await reader.read(file);
The result
is a is the original payload that was encoded into the series of QR codes.
The Writer
class accepts an optional configuration object that can be used to customize the behavior of the writer. The following options are available:
{
logLevel: 'silent' | 'trace' | 'debug' | 'info' | 'warn' | 'error', // Default: 'silent'
frameProcessor: FrameProcessor, // Default: new WebRTCProcessor()
}
FAQs
The Flipbook reader is responsible for reading "flipbooks" created by the [Flipbook writer](https://github.com/cereallarceny/flipbook/tree/main/packages/writer). It can be used to decode a series of QR codes into a single payload.
The npm package @flipbookqr/reader receives a total of 3 weekly downloads. As such, @flipbookqr/reader popularity was classified as not popular.
We found that @flipbookqr/reader demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
PyPI now supports iOS and Android wheels, making it easier for Python developers to distribute mobile packages.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.