Skip to content
Skillpedia
Websites & UI (frontend)15k Β· #10921

using-lynx-api-docs

What it does

Makes the assistant look up the installed Lynx API documentation before it writes or changes Lynx code. It is for developers building apps on the Lynx rendering platform.

When to use it

  • βœ“When you ask the assistant to write or change a Lynx page, template or component.
  • βœ“When a Lynx layout or CSS style behaves differently from the web.
  • βœ“When you ask it to review Lynx code or move a web page over to Lynx.

Skill link

https://github.com/lynx-family/lynx/blob/develop/ai/skills/lynx-api-docs/skills/using-lynx-api-docs/SKILL.md

Copy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.

How to use

The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.

Ready-to-paste message

Use this skill to help me: https://github.com/lynx-family/lynx/blob/develop/ai/skills/lynx-api-docs/skills/using-lynx-api-docs/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
Want your AI to find skills like this on its own?Install the free Skillpedia MCP: one line, and it searches 15,000+ skills before each task.Install in 1 minute β†’

Example of what to ask your AI

β€œFix the layout of my Lynx page so the image sits beside the text, using the correct Lynx elements.”

5 new skills a week. 1 minute to read.

How it works

The assistant finds the right Lynx documentation for the task, reads it, and then writes code with the platform's own elements and styling rules instead of assuming web behavior.

Technical content (original SKILL.md)

Original text by the author, straight from GitHub.

Using Lynx API Docs

Overview

Pre-training knowledge is insufficient for Lynx. Lynx is a rendering platform (like a browser) with its own elements, non-standard CSS behavior, unique layout systems, and web-incompatible defaults. Always retrieve from the installed API docs before writing or modifying Lynx page code.

Core Rule

MUST ALWAYS read the relevant API docs BEFORE writing or editing any Lynx code.

Do not rely on web CSS knowledge. Do not assume standard HTML behavior. Do not guess element APIs. Lynx is a distinct platform with its own rules.

Why Web Knowledge Fails

Lynx is not a web browser. Web assumptions produce broken Lynx code:

  • Elements: <view>, <text>, <image> β€” not <div>, <span>, <img>
  • CSS defaults: box-sizing: auto normally uses border-box sizing; no margin collapsing; Linear layout (not Flow)
  • Properties: Many CSS properties are unsupported or behave differently β€” always check css/ docs

Every web assumption is a potential bug.

How to Use the Docs

  1. Identify what you're working on (layout, CSS, element, migration, pattern)
  2. Look up the relevant doc file from the table below
  3. Read the doc BEFORE writing or editing code
  4. Apply the rules and constraints from the doc
  5. If uncertain, search the elements/ or css/ directories

Quick Reference

Task Read These Files First
Choose layout layout/linear-layout.md (default), layout/flex-layout.md, layout/grid-layout.md, layout/relative-layout.md
CSS properties/units css/supported-properties.md, css/values-and-units.md
CSS selectors css/selectors.md, css/pseudo-classes.md
Use an element elements/<element-name>.md
Migrate from web lynx-vs-web/migration-guide.md, lynx-vs-web/css-differences.md
Theming/animation/responsive patterns/theming.md, patterns/animation.md, patterns/responsive.md
General lookup quick-reference.md, best-practices.md

Core Rules

The compact layout decision rules and key CSS constraints are documented in quick-reference.md. Most critical:

  • Text must use <text> component
  • Box sizing initially uses auto, normally with border-box sizing; set an explicit value when compatibility settings may differ
  • No margin collapsing
  • Use rem + vw for screen adaptation

Red Flags β€” Stop and Read Docs

  • Adding a <div> or <span> β†’ Lynx uses <view>, <text>
  • Using margin without checking if margin collapsing applies β†’ It doesn't
  • Assuming content-box β†’ auto normally uses border-box sizing; check css/supported-properties.md#box-model
  • Using web CSS properties without checking css/supported-properties.md
  • Guessing element attributes β†’ Read elements/<name>.md
  • Choosing rpx for web-portable code β†’ rpx is Lynx-specific; use rem + vw for web compatibility
  • Writing plain text without <text> wrapper β†’ Invalid in Lynx
  • Using web pseudo-classes without checking css/pseudo-classes.md
  • Assuming standard HTML flow layout β†’ Lynx uses linear layout by default
FAQ

Why not just use normal web knowledge?

Lynx is its own rendering platform with its own elements and layout defaults, so web assumptions often produce broken code.

Which files does it cover?

Lynx-specific files, including .ttml pages and Lynx TSX files, are covered by this guidance.

Does it need the docs installed?

Yes. The skill tells the assistant to search the installed API docs before it acts.

Details

Original description by the author

Provides authoritative guidance for Lynx development involving pages, templates, components, CSS, layouts, elements, web migration, rendering or styling bugs, and code review. Applies to *.ttml, Lynx *.tsx, and all Lynx-specific files, and requires searching the installed API docs before acting.

repo: lynx-family/lynx

Popularity

GitHub stars
15k
Ranking position
#10921
License
Apache-2.0
Updated
11/2/2026

Is this skill useful?

0

Sign in to vote.

Comments

  • …

More skills from this repository

Similar skills