The plugin now properly detects and uses the file's language based on
its extension, rather than focusing on TypeScript.
Changes:
- Updated all system prompts to use {{language}} placeholder
- Removed hardcoded TypeScript references
- Expanded language mappings to support 50+ file extensions:
- JavaScript/TypeScript (js, ts, jsx, tsx, mjs, cjs)
- Python (py, pyw, pyx)
- Systems (c, cpp, rs, go, zig, nim)
- JVM (java, kt, scala, clj)
- Web (html, css, scss, vue, svelte)
- Scripting (lua, rb, php, sh, bash)
- .NET (cs, fs, vb)
- Data (json, yaml, toml, sql, graphql)
- And many more...
Improved prompts and code extraction to ensure generated code:
- Matches the file type and existing code structure
- Contains NO markdown code blocks (```)
- Contains NO explanations or comments about what was done
- Is ready to be directly inserted into the target file
Changes:
- Enhanced system prompts with stricter "ABSOLUTE RULES"
- Added explicit instructions about no markdown in user prompts
- Improved extract_code() to strip markdown and explanations
- Added processing notification with prompt preview