npx prettier --write src/example.js. 現在我們可以在 package.json 加入新的 script : "scripts": { ... "format": "prettier --write \"**/*.+(js|json)\"" },.
確定! 回上一頁