Open-Source Wikis

/

Astro

/

Packages

/

Internal helper packages

withastro/astro

Internal helper packages

A handful of small workspace packages that exist to share code without coupling the consumers. They are published to npm because adapters and integrations developed outside this monorepo also depend on them.

@astrojs/internal-helpers

packages/internal-helpers/ exports utility functions used across the framework and its integrations.

  • path — URL/path helpers (appendForwardSlash, removeBase, prependForwardSlash, …).
  • remoteRemotePattern matcher for the image service config.
  • fs — small filesystem wrappers.

Used heavily by the adapter and image service packages. The exported RemotePattern type is re-exported from astro/types.

@astrojs/underscore-redirects

packages/underscore-redirects/ is a single-purpose library that turns Astro's redirect manifest into the _redirects format Netlify and similar hosts consume. The Netlify adapter imports it directly.

import { createRedirects } from '@astrojs/underscore-redirects';

@astrojs/prism

packages/astro-prism/ is the legacy Prism syntax-highlighting helper used by the historical <Prism> component. New code should prefer the Shiki-based highlighter that ships with @astrojs/markdown-remark@astrojs/prism is kept around for backwards compatibility.

Built by Factory AutoWiki from public repository content. It is a generated preview for codebase exploration, not source-maintained documentation.

Internal helper packages – Astro wiki | Factory