ReviewOS

stacks/ts-slug

docs: align introductory examples with the public slugify contract

#1840
Open chris opened this 2 hours ago ·
2 hours ago

The published ts-slug@0.2.1 README Quick Example imports a default slug and suggests an alternative named slug import. The actual published root exports are slugify, getWholeCharAndI, and TRANSLITERATED_SCRIPT; neither documented import exists. Its Japanese example also expects konnichihasei-jie, while the actual supported default result is こんにちは世界.

Observed through a normal frozen Stacks consumer install, with all nine installed files byte-equal to the original public archive. Source 8d9af5d8346eb4dc7194ec9ef56df6b7619285c6, archive SHA256 375de442aad996c7bb811370c8363fe123982a7a62e1777d9404a573addc4254. Actual public calls returned hello-world, こんにちは世界, and schoene-gruesse for the current README inputs. The existing runtime API works; the documented entrypoint and one expected value do not.

Acceptance:

  • Correct the README examples to use the existing public slugify export and accurately describe Unicode retention and optional transliteration. Do not add an unnecessary runtime alias to make stale prose pass.
  • Audit the other published usage examples against actual public imports and supported options/results.
  • Retain a meaningful public example check so future export or behavior changes cannot silently invalidate the introductory example.
  • Run owning source checks, use the existing patch release command, and verify the actual published README/public entries.

Found while preserving the concurrent Stacks slug adoption in https://github.com/stacksjs/stacks/commit/683d1d80de0e61ca60329bd6498b9beb7ab2a7ee and the source-first delivery contract https://github.com/stacksjs/stacks/issues/2958. This documentation defect is separate from the already verified public runtime and is not evidence of a native or game failure.

Sign in to comment on this issue.