Skip to content

Add source map supports #68

@wherewhere

Description

@wherewhere

Clear and concise description of the problem

For now, the source map will ignore the markdown component. It will be better to have a source map with source of generated html or markdown better.

Suggested solution

Is this broken the source map?

export function createMarkdown(options: ResolvedOptions) {
    ...
    return {
      code,
      map: { mappings: '' } as any,
    }
}

(And the defined missing excerpt and frontmatter. It better to be:

declare module "*.md" {
    import type { defineComponent, ComponentObjectPropsOptions, HTMLAttributes } from "vue";
    const frontmatter: { [key: string]: string | typeof frontmatter | undefined };
    const component: ReturnType<typeof defineComponent<HTMLAttributes, ComponentObjectPropsOptions, string, {}, {}, string, { excerpt?: string, frontmatter?: typeof frontmatter }>>;
    export default component;
}

Validations

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions