Skip to content

Doesn't understand {@const x = 42} of Svelte v3.46.0 #272

@tv42

Description

@tv42

Svelte's latest release added @const to the template syntax. This plugin doesn't understand the new syntax and errors out.

https://github.com/sveltejs/svelte/blob/master/CHANGELOG.md#3460

npm run format
...
[error] src/routes/foo.svelte: Error: unknown node type: ConstTag
[error]     at Object.print (/home/blah/blah/node_modules/prettier-plugin-svelte/plugin.js:1328:11)
[error]     at callPluginPrintFunction (/home/blah/blah/node_modules/prettier/index.js:14259:21)

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