Skip to content

[Bug] templateExportDefault: true does not add export default correctlyΒ #402

@davidtaylorhq

Description

@davidtaylorhq

When templateExportDefault: true, I would expect this gjs file:

<template>Hello world</template>

to be transformed to

export default <template>Hello world</template>

However, this does not happen. The file remains unchanged.

This issue is also shown in the snapshot tests in this repo:

exports[`config > templateExportDefault: true > it formats ../cases/gjs/simple.gjs 1`] = `
"<template>what</template>
"
`;

^^ this assertion should be export default <template>what</template>

🌍 Environment

  • prettier-plugin-ember-template-tag version: 2.1.0

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