hyperbrew / bolt-cep

A lightning-fast boilerplate for building Adobe CEP Extensions in React, Vue, or Svelte built on Vite + TypeScript + Sass
MIT License
296 stars 41 forks source link

jsx strings are garbled(jsx字符串乱码问题) #122

Closed divib-cc closed 5 months ago

divib-cc commented 5 months ago

When writing JSX, Chinese strings inside double quotes ("") may appear as garbled text, for example, alert("哈哈") displays as alert("鍝堝搱"). However, using template strings with backticks (`) will display correctly, for example, alert(哈哈) remains as alert(哈哈`).

aztack commented 5 months ago

Check the file encoding If you are using Windows and ensure it is set to utf-8.

divib-cc commented 5 months ago

Solved cep.config.ts build: { jsxBin: 'replace', sourceMap: false, },