Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

There is a problem with the export type for typescript #2558

Closed
Jeggery opened this issue May 24, 2022 · 2 comments
Closed

There is a problem with the export type for typescript #2558

Jeggery opened this issue May 24, 2022 · 2 comments
Labels
locked Please open a new issue and fill out the template instead of commenting.

Comments

@Jeggery
Copy link

Jeggery commented May 24, 2022

example:
` ["ERROR" - 下午4:27:26] Error formatting document.
["ERROR" - 下午4:27:26] Declaration or statement expected. (5:1)
3 | import DiffusionWave from '../../../utils/diffusionWave';
4 | import LineManager from './LineManager';

5 | export type { ISpriteMark } from './libs/SpriteClassify';
| ^
6 |
7 | type Vec = Pick<Vector3, 'x' | 'y' | 'z'>;
8 |
SyntaxError: Declaration or statement expected. (5:1)
3 | import DiffusionWave from '../../../utils/diffusionWave';
4 | import LineManager from './LineManager';
5 | export type { ISpriteMark } from './libs/SpriteClassify';
| ^
6 |
7 | type Vec = Pick<Vector3, 'x' | 'y' | 'z'>;`

For the new version of typescript, there is a problem with export type and prettier

@ntotten
Copy link
Member

ntotten commented Aug 20, 2022

Recommendation: Upgrade to the latest version of prettier.

Explanation: You are likely using a newer version of Typescript than the version of prettier you have installed supports. Typescript features are added in new prettier releases. See the prettier blog to learn more about what features of typescript are enabled for each version of prettier: https://prettier.io/blog/

@ntotten ntotten closed this as completed Aug 20, 2022
@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot added the locked Please open a new issue and fill out the template instead of commenting. label Nov 19, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 19, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
locked Please open a new issue and fill out the template instead of commenting.
Projects
None yet
Development

No branches or pull requests

2 participants