Repository: withastro/astro
File: packages/astro/src/core/errors/errors-data.ts (TypeScript)

Code before:
 * Astro encountered an unknown error while starting one of its CLI commands. The error message should contain more information.
 *
 * If you can reliably cause this error to happen, we'd appreciate if you could [open an issue](https://astro.build/issues/)
 */
export const UnknownCLIError = {
	name: 'UnknownCLIError',
	title: 'Unknown CLI Error.',
} satisfies ErrorData;
/**
 * @docs
 * @description
 * `astro sync` command failed to generate content collection types.
 * @see
 * - [Content collections documentation](https://docs.astro.build/en/guides/content-collections/)
 */
export const GenerateContentTypesError = {
	name: 'GenerateContentTypesError',
	title: 'Failed to generate content types.',
	message: (errorMessage: string) =>
		`\`astro sync\` command failed to generate content collection types: ${errorMessage}`,
	hint: (fileName?: string) =>
		`This error is often caused by a syntax error inside your content, or your content configuration file. Check your ${fileName ?? 'content config'} file for typos.`,
} satisfies ErrorData;
/**
 * @docs
 * @message No parser found for file `users.csv`. Pass a parser to the `file` loader (e.g. `parser: csv`).
 * @see
 *  - [parsers](https://docs.astro.build/en/guides/imports/#parsers)
 * @description
 * Thrown when the `file` loader can’t determine which parser to use.
 */
export const FileParserNotFound = {
	name: 'FileParserNotFound',
	title: 'File parser not found',
	message: (fileName: string) =>
		`No parser was found for '${fileName}'. Pass a parser function (e.g. \`parser: mdx\`) to the \`file\` loader.`,
} satisfies ErrorData;

/**
 * @docs
 * @message Glob patterns are not supported in the `file` loader. Use the `glob` loader instead.
 * @see
 *  - [glob patterns](https://docs.astro.build/en/guides/imports/#glob-patterns)
 * @description
 * Thrown when a glob pattern is supplied to the `file` loader.
 */
export const FileGlobNotSupported = {
	name: 'FileGlobNotSupported',
	title: 'Glob patterns are not supported in the file loader',
	message:
		'Glob patterns are not supported in the `file` loader. Use the `glob` loader instead.',

Review comment (suggestion):
```suggestion
```
We don't use this field for docs! It's generated from the `message` in the function!

Code after:
export const ConfigLegacyKey = {
	name: 'ConfigLegacyKey',
	title: 'Legacy configuration detected.',
	message: (legacyConfigKey: string) => `Legacy configuration detected: \`${legacyConfigKey}\`.`,
	hint: 'Please update your configuration to the new format.\nSee https://astro.build/config for more information.',
} satisfies ErrorData;
/**
 * @docs
 * @kind heading
 * @name CLI Errors
 */
// CLI Errors
/**
 * @docs
 * @description
 * Astro encountered an unknown error while starting one of its CLI commands. The error message should contain more information.
 *
 * If you can reliably cause this error to happen, we'd appreciate if you could [open an issue](https://astro.build/issues/)
 */
export const UnknownCLIError = {
	name: 'UnknownCLIError',
	title: 'Unknown CLI Error.',
} satisfies ErrorData;
/**
 * @docs
 * @description
 * `astro sync` command failed to generate content collection types.
 * @see
 * - [Content collections documentation](https://docs.astro.build/en/guides/content-collections/)
 */
export const GenerateContentTypesError = {
	name: 'GenerateContentTypesError',
	title: 'Failed to generate content types.',
	message: (errorMessage: string) =>
		`\`astro sync\` command failed to generate content collection types: ${errorMessage}`,
	hint: (fileName?: string) =>
		`This error is often caused by a syntax error inside your content, or your content configuration file. Check your ${fileName ?? 'content config'} file for typos.`,
} satisfies ErrorData;

/**
 * @docs
 * @kind heading
 * @name Content Collection Errors
 */
// Content Collection Errors
/**
 * @docs
 * @description
 * Astro encountered an unknown error loading your content collections.
 * This can be caused by certain errors inside your `src/content.config.ts` file or some internal errors.
 *