Run Ratchet via jscodeshift to convert JavaScript/JSX files to TypeScript/TSX from any project directory, resolving paths correctly.
- Place
ts-convert.jsinscripts/. - Add to
package.json:
"scripts": {
Run Ratchet via jscodeshift to convert JavaScript/JSX files to TypeScript/TSX from any project directory, resolving paths correctly.
ts-convert.js in scripts/.package.json:
"scripts": {
| { | |
| "workbench.colorCustomizations": { | |
| // 🔴 Active Tab Customization | |
| "tab.activeBorderTop": "#FF0000", // Red top border for the active tab to indicate focus | |
| "tab.activeBackground": "#FF000044", // Semi-transparent red background for active tab for better visibility | |
| // 🟡 Highlighting Unused Code | |
| "editorUnnecessaryCode.border": "#FFFF00", // Yellow border to outline unused variables clearly | |
| "editorUnnecessaryCode.background": "#FFFF0080", // Semi-transparent yellow background to indicate unused code |
| # Elevate permissions | |
| # https://stackoverflow.com/a/11440595/3191720 | |
| if (-NOT ([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole] "Administrator")) | |
| { | |
| $arguments = "& '" +$myinvocation.mycommand.definition + "'" | |
| Start-Process powershell -Verb runAs -ArgumentList $arguments | |
| Break | |
| } |