|
🎨 Smart FormattingMulti-language formatting for VBScript, HTML, CSS, and JavaScript with customisable keyword casing |
🌈 Syntax HighlightingBeautiful, theme-compatible syntax colouring for ASP regions and SQL queries |
💡 IntelliSenseAuto-completion for ASP objects, VBScript keywords, HTML, CSS, and JavaScript |
📸 See It In Action
🎨 Formatting Before & After
Colours in these previews are made possible by the Catppuccin Theme
🌈 Syntax Highlighting
🚀 Installation
- Install from VS Code Extensions Marketplace (search for "Classic ASP Language Support")
- Or install from
.vsixfile: Extensions → Install from VSIX
📖 Usage
| Action | Shortcut |
|---|---|
| Format Document | Alt + Shift + F (Windows/Linux)Option + Shift + F (Mac) |
| Trigger IntelliSense | Start typing or Ctrl + Space |
| Insert Snippet | Type prefix and press Tab |
🎯 Key Features
🎨 Multi-Language Formatting
- ✅ VBScript: Smart indentation for all control structures (If/For/While/Select Case/Sub/Function)
- ✅ HTML/CSS/JavaScript: Professional formatting powered by Prettier
- ✅ SQL: Proper indentation for SQL queries inside ASP strings
- ✅ Customisable keyword casing: Choose lowercase, UPPERCASE, or PascalCase
- ✅ Automatic operator spacing: Proper spacing around
=,+,&, etc. - ✅ Multi-block support: Handles structures that span across multiple
<% %>blocks - ✅ Inline ASP support: Formats ASP expressions in HTML attributes
💡 IntelliSense & Auto-Completion
- HTML: Tag and attribute suggestions with smart auto-closing
- CSS: Property completion inside in-line and
<style>tags - JavaScript: Keyword and object completion inside
<script>tags - ASP/VBScript: Response, Request, Server, Session, Application objects and VBScript keywords
📝 Snippets
- ✅ Pre-built snippets for HTML, ASP, and JavaScript patterns
- ✅ Quick insertion for common structures (loops, conditionals, database connections)
🌈 Syntax Highlighting
- ✅ ASP region highlighting with customisable colours
- ✅ Compatible with all VS Code themes
- ✅ Comprehensive SQL syntax colouring with advanced support
- ✅ Toggleable highlighting for
<% %>blocks - ✅ Distinct colours for keywords, functions, data types, operators, and parameters
⚙️ Configuration
⚙️ Formatter Settings
Access settings via File → Preferences → Settings and search for "Classic ASP Language Support".
| Setting | Default | Options | Description |
|---|---|---|---|
aspLanguageSupport.keywordCase |
PascalCase |
lowercase, UPPERCASE, PascalCase |
ASP/VBScript keyword formatting style |
aspLanguageSupport.useTabs |
false |
true, false |
Use tabs instead of spaces for ASP code indentation |
aspLanguageSupport.indentSize |
2 |
2, 4, 8 |
Number of spaces per indentation level for ASP code |
aspLanguageSupport.asptagsOnSameLine |
false |
true, false |
Keep <% %> on same line as code (default: separate lines) |
🎨 Prettier Settings (HTML/CSS/JS)
| Setting | Default | Options | Description |
|---|---|---|---|
aspLanguageSupport.prettier.printWidth |
80 |
number | Maximum line length (Prettier) |
aspLanguageSupport.prettier.tabWidth |
2 |
2, 4, 8 |
Spaces per indentation level (Prettier) |
aspLanguageSupport.prettier.useTabs |
false |
true, false |
Use tabs instead of spaces (Prettier) |
aspLanguageSupport.prettier.bracketSameLine |
true |
true, false |
Put > of multi-line elements on last line (Prettier) |
aspLanguageSupport.prettier.semi |
true |
true, false |
Add semicolons to JavaScript statements (Prettier) |
aspLanguageSupport.prettier.singleQuote |
false |
true, false |
Use single quotes in JavaScript (Prettier) |
aspLanguageSupport.prettier.arrowParens |
always |
always, avoid |
Arrow function parameter parentheses (Prettier) |
aspLanguageSupport.prettier.trailingComma |
es5 |
none, es5, all |
Trailing comma style (Prettier) |
aspLanguageSupport.prettier.endOfLine |
lf |
lf, crlf, cr, auto |
Line ending style (Prettier) |
aspLanguageSupport.prettier.htmlWhitespaceSensitivity |
css |
css, strict, ignore |
HTML whitespace handling (Prettier) |
🌈 Completion & Highlighting Settings
| Setting | Default | Description |
|---|---|---|
aspLanguageSupport.enableSQLHighlighting |
true |
Enable SQL syntax highlighting inside double-quoted strings (requires reload) |
aspLanguageSupport.highlightAspRegions |
true |
Highlight ASP code regions with background colours |
aspLanguageSupport.bracketLightColor |
rgba(255, 100, 0, 0.2) |
ASP bracket <% %> colour (light theme) |
aspLanguageSupport.bracketDarkColor |
rgba(0, 100, 255, 0.2) |
ASP bracket <% %> colour (dark theme) |
aspLanguageSupport.codeBlockLightColor |
rgba(100, 100, 100, 0.1) |
ASP code block background (light theme) |
aspLanguageSupport.codeBlockDarkColor |
rgba(220, 220, 220, 0.1) |
ASP code block background (dark theme) |
💡 IntelliSense & Completion
| Setting | Default | Description |
|---|---|---|
aspLanguageSupport.enableAspCompletion |
true |
Enable ASP object and VBScript keyword auto-completion |
📋 Known Limitations
Note: These are edge cases that may require manual adjustment
- ASP blocks must be properly closed (
<% ... %>) - Complex mixed HTML/ASP structures may require manual adjustment
- Prettier settings only apply to HTML/CSS/JS, not VBScript
🛠️ Development
Building from Source
Prerequisites
- Node.js 16.x or higher
- Visual Studio Code 1.80.0 or higher
Build Steps
# Clone the repository
git clone https://github.com/ashtonckj/Classic-ASP-Language-Support.git
cd Classic-ASP-Language-Support
# Install dependencies
npm install
# Compile TypeScript
npm run compile
# Run extension in debug mode
# Press F5 in VS Code
🤝 Contributing
Contributions are welcome! If you have ideas, bug reports, or want to improve the extension:
- 🍴 Fork the repository
- 🌿 Create a feature branch (
git checkout -b feature/amazing-feature) - 💾 Commit your changes (
git commit -m 'Add amazing feature') - 📤 Push to the branch (
git push origin feature/amazing-feature) - 🎉 Open a Pull Request
🙏 Acknowledgements
This extension wouldn't be possible without these amazing projects:
- Prettier - HTML, CSS, and JavaScript formatting engine
- Zachary Becknell ( ASP Classic Support ) - ASP region highlighting implementation
- Jintae Joo ( Classic ASP Syntaxes and Snippets ) - Snippets inspiration and reference
If you find this extension helpful, please consider leaving a ⭐ on GitHub and a rating on the VS Code Marketplace!
Made with ❤️ for the Classic ASP community