Skip to content

[docs] Theme customization docs using different function names than implementation #45

@joan-teriihoania

Description

@joan-teriihoania

Hello!

Note! This has been created as a mirror to the original issue in the main repository. To which repository this issue belongs to will depends on whather this is a naming issue in the package's implementation, or a documentation typo. For now, I've elected to raise the issue on both.

The documentation states that the following helpers are exported by nativewind/theme:

However, at the moment in the nativewind's theme package, only the following are exported:

  • hairlineWidth,
  • platformSelect,
  • pixelScaleSelect,
  • fontScaleSelect,
  • pixelScale,
  • fontScale,
  • roundToNearestPixel,
  • platformColor,
  • getPixelSizeForLayoutSize,

It seems that pixelScale and pixelScaleSelect were used in react-native-css-interop but the docs mention pixelRatio and pixelRatioSelect. This issue is happening on the main branch with the current v4 documentation.

Is this a typo? Or do pixelRatio and pixelScale have different behaviours.


See docs: https://www.nativewind.dev/docs/customization/theme#pixelratio
See implementation: https://github.com/nativewind/nativewind/blob/main/packages/nativewind/src/theme.ts

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions