Closed NullVoxPopuli closed 10 months ago
The plugin as written doesn't expect <template>
in that position. Hopefully it will be fixed with https://github.com/gitKrystan/prettier-plugin-ember-template-tag/pull/162 .
The plugin as written doesn't expect in that position.
It shouldn't have expectations of anything :sweat_smile:
Hopefully it will be fixed with https://github.com/gitKrystan/prettier-plugin-ember-template-tag/pull/162 .
yeah, I'm thinking it would, real parser and all!
Confirmed fixed by https://github.com/gitKrystan/prettier-plugin-ember-template-tag/pull/162. Test added here: https://github.com/gitKrystan/prettier-plugin-ember-template-tag/pull/188
NOTE that the output currently has a comma, which makes sense since in the current implementation, it's a function argument. If this is the syntax that ends up sticking, we might want to special case it.
output (copy-pasta'ed from snapshot so has some extra escaping):
import Layout from \\"docs-app/components/layout\\";
import pageTitle from \\"ember-page-title/helpers/page-title\\";
import Route from \\"ember-route-template\\";
export default Route(
<template>
{{pageTitle \\"ember-primitives\\"}}
<Layout />
</template>,
);
🐞 Describe the Bug
Error:
Input
🔬 Minimal Reproduction
the above file this config:
😕 Actual Behavior
error
🤔 Expected Behavior
no error
🌍 Environment