JavaScript Library for PDF Layers (OCGs)
PSPDFKit for Web includes support for toggling the visibility of optional content group (OCG) layers. It offers developers a robust API for programmatic display of OCG layers, as well as a beautiful UI for users to enable and disable layer visibility.
Nutrient SDKs are deployed in some of the world’s most popular applications, such as those made by Autodesk, Disney, UBS, Dropbox, IBM, and Lufthansa.
Working with PDF layers (OCG layers) is available when using the Web SDK in standalone operational mode.
Key Capabilities
-
Built-in UI — Enable or disable OCG layer visibility using the UI
-
Programmatic — Programmatically toggle or lock OCG layer visibility
-
Layer Nesting — Retain the nested hierarchy of OCG layers
-
Extendable — Add form fill, annotation, editing, and more
Guides for OCG Layers
Introduction to PDF Layers (OCGs)
Learn about PDF OCG layers
Show and Hide
How to programmatically hide, show, or lock PDF OCG layers
Built-in UI
Learn how end users can toggle PDF OCG layers with the built-in UI