For AI agents: the complete documentation index is available at /llms.txt, the full documentation bundle is available at /llms-full.txt, and this page is available as Markdown at /api/index.md.

API Reference

Exact signatures, attributes and options for every AngularLynx package and element. To learn a feature step by step, start with the Guide.

Packages

PackageReferenceWhat it covers
@blotch/angular-lynxPackage overviewThe runtime: bootstrap, routing, elements, animation and services
@blotch/angular-lynxSchematicsng add, ng generate component and the other schematics
@blotch/angular-lynx-buildBuildersThe builders behind ng build, ng serve and ng test
@blotch/angular-lynx-testing-libraryTesting libraryrender(), events and queries for component tests
@blotch/angular-lynx-testing-libraryEvent referenceEvery fireEvent method and the template binding it runs

Runtime

App setup and UI

PageWhat it covers
BootstrapbootstrapApplication, provideRenderer, loadLazyBundle
RoutingprovideRouter, the stack and tab outlets, and the location classes
ElementsLYNX_ELEMENTS, every element directive, form value accessors
Element events$event's types, pointer events and each element's own events
Animationanimate(), <lynx-transition>, <lynx-transition-group>
AccessibilityLynxAccessibility and the accessibility-* attributes
FontsLynxFont: load fonts at runtime
PortalLynxPortal: open overlays from code
ExposureLynxExposure, LynxGlobalExposure and the exposure-* attributes
Text measureLynxTextMeasure: text width and line breaks

Device

PageWhat it covers
ThemeLynxTheme: light or dark appearance
Safe areaLynxSafeArea and the SAFE_AREA_INSET_* constants
ViewportLynxViewport: the page's and the window's size, following a fold
LocaleLynxLocale, provideLocale, getLynxAppLocale
System infoLynxSystemInfo: platform and screen size
App stateLynxAppState: whether the app is in the foreground
NetworkLynxNetwork: whether the phone is online
ClipboardLynxClipboard: copy and paste text
HapticsLynxHaptics: tap the phone, as native controls do

Hardware

PageWhat it covers
BluetoothLynxBluetooth: find Bluetooth LE devices and talk to them
NFCLynxNfc: read and write NFC tags
GeolocationLynxGeolocation: find where the phone is, once or as it moves
MotionLynxMotion: read the motion sensors and compass, and hear a shake
BiometricsLynxBiometrics: confirm the person with Face ID or a fingerprint
Barcode scannerLynxBarcodeScanner: read a QR code or a barcode with the camera
Audio playerLynxAudioPlayer: play audio, on the lock screen and in the background
Audio recorderLynxAudioRecorder: record audio from the microphone
Wi-FiLynxWifi: read the phone's Wi-Fi network and join another, to set up a device

Media

PageWhat it covers
Image pickerLynxImagePicker: let someone pick a photo
Photo libraryLynxPhotoLibrary: save an image or a video to the photo library
File pickerLynxFilePicker: let someone pick a document, or save a file
ContactsLynxContacts: pick a contact, a number or an address, or read the address book
CalendarLynxCalendar: add an event to the person's calendar
PageWhat it covers
ShareLynxShare: open the share sheet to send files and links, or save a photo
Share targetLynxShareTarget: receive what other apps share to the app
LinkingLynxLinking: open links in the browser, a browser sheet or another app
ShortcutsLynxShortcuts: hear the shortcuts run from Siri or the app icon's menu

Accounts

PageWhat it covers
Web auth sessionLynxWebAuthSession: sign in through a web page
Sign in with AppleLynxAppleSignIn: sign in with Apple's own sheet on iOS
Store reviewLynxStoreReview: ask for an App Store or Google Play rating in the app
TrackingLynxTracking: ask whether the app may track, for ads and attribution

Host app

PageWhat it covers
Host dataLynxInitData, LynxGlobalData, registerDataProcessors
Native moduleLynxNativeModule: call the host app's native code
Back buttonLynxBackButton: hear Android's back button and back gesture
Splash screenLynxSplashScreen: keep the splash screen up until the app is ready
reportFullyDrawnreportFullyDrawn(): tell the phone the first screen is usable

Storage, network and debugging

PageWhat it covers
Persistent storageLynxLocalStorage, LynxSecureStorage: data kept after the app closes
Session storageLynxSessionStorage: state shared between pages
Resource prefetchLynxResourcePrefetch: preload images and videos
Errors and loggingLynxErrorHandler, LynxLogger
DevToolsLynxDevTools, LynxPerformance

Gestures

PageWhat it covers
GesturesThe [lynxGesture] directive and composing gestures
Gesture typesTap, pan, fling, long press, pinch and rotation: options and events
Gesture lifecycleGesture states, callbacks and GestureStateManager

Main-thread scripts

Code that runs on the main thread, right inside native events. Read Main-thread scripts first.

PageWhat it covers
mainThreadFnDefine a function that runs on the main thread
LynxMainThreadEventBind main-thread functions to native events
MainThreadRefKeep a value between main-thread script calls
LynxMainThreadCall a main-thread function from Angular code
backgroundFnCall background-thread code from the main thread

Elements

The native elements your templates use instead of HTML. See Elements and layout for how they compare with HTML.

ElementUse it for
<view>Layout and grouping, like <div>
<text>All visible text
<image>Local and remote images
<scroll-view>A scrolling area
<list>Long lists that render only the visible rows
<refresh>Pull to refresh
<scroll-coordinator>Collapsing headers and sticky toolbars
<viewpager>Pages you swipe between
<input>Single-line text input
<textarea>Multi-line text input
<overlay>Content above the page, such as dialogs
<frame>Another Lynx bundle inside this page
<block>Grouping without a layout box, like <ng-container>
<svg>SVG graphics
<canvas>2D drawing, and 3D with WebGL2 for three.js
<blur-view>Frosted, blurred backgrounds
<video>Video playback
<webview>Web pages inside your app
<apple-sign-in-button>The button that starts Sign in with Apple
<title-bar-view>The draggable area of a desktop window's title bar
<cover-view>Content that draws above a desktop <webview>