Skip to content

Commit de71b41

Browse files
committed
Rewrite the ReadMe
1 parent b985f2d commit de71b41

File tree

1 file changed

+53
-14
lines changed

1 file changed

+53
-14
lines changed

README.md

Lines changed: 53 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,58 +1,97 @@
11
# [HTML (C#)][pkg]
22

3-
[Sublime Text][st] [syntax highlighting][ss-docs] for `.cshtml`, `.aspx`, and similar files.
3+
This project contains
4+
[syntax highlighting][ss-docs]
5+
and completions
6+
in [Sublime Text][st]
7+
for *.cshtml*, *.aspx*, and similar files.
8+
It was originally created for .Net WebForms,
9+
but later expanded
10+
to support Razor syntax as well.
411

512
## WebForms
613

7-
The old ASP.Net style pages that necessitated creation of this package. Post-Visual Basic ASP, but pre-Razor.
14+
Microsoft's ASP.Net pages with C#
15+
were the first thing
16+
that this package supported.
17+
The syntaxes also work for .Net MVC.
18+
The ASP syntax
19+
that Sublime Text ships with
20+
only supports Visual Basic.
821

922
### Current support
1023

1124
#### Highlighting
1225

13-
- Embedded C# (`<script runat="server">`)
26+
- Embedded C# script blocks (`<script runat="server">`)
1427
+ The `runat="server"` must immediately follow the tag opening.
15-
- `<%` expressions (including `<%=`, `<%#`, `<%:`, `<%$`, `<%--`)
28+
- ASP.Net inline expressions
29+
+ Server-side comments (`<%--`)
30+
+ Directives (`<%@`)
31+
+ Output (`<%=`, `<%#`, `<%:`, `<%#:`, `<%$`)
32+
+ Embedded code blocks (`<%`)
1633

1734
#### Functionality
1835

19-
- Hotkey comment/uncomment server-side comments (<kbd>Ctrl</kbd>+<kbd>/</kbd> or <kbd>Cmd</kbd>+<kbd>/</kbd>)
20-
36+
- Hotkey comment/uncomment server-side comments
37+
(<kbd>Ctrl</kbd>+<kbd>/</kbd> or <kbd>Cmd</kbd>+<kbd>/</kbd>)
2138
- Snippets for `<%`-ish expressions
2239
- Snippets for some directives (Try `page` or `import`)
2340
+ Default attributes are subject to change.
24-
- Snippets may require <kbd>Ctrl</kbd>+<kbd>space</kbd>, depending on your environment.
41+
- Snippets may require <kbd>Ctrl</kbd>+<kbd>Space</kbd>,
42+
depending on your environment.
2543
- Some autocomplete within directives.
26-
- Basic "Open `CodeBehind`" shortcut for frontend pages.
44+
- Basic "Open CodeBehind" shortcut for frontend pages.
45+
- Naive "Open Front End" shortcut for codebehind files.
2746

28-
### Future support (maybe)
47+
### To-Do (maybe)
2948

3049
- Identify more attributes of directives
31-
- Autocomplete ASP builtins
50+
- Snippets and/or completions for ASP.Net builtins
51+
- Refactor C# Handler syntax (*.ashx*)
3252

3353
### Known issues
3454

3555
- Nothing yet? &#x1f91e;
56+
- File new issues [on GitHub][gh]
3657

3758

3859
## Razor
3960

40-
The simplified, less-intrusive frontend templating syntax that supplanted WebForms.
61+
Microsoft later released
62+
a simplified, less-intrusive frontend templating syntax
63+
that supplanted WebForms.
4164

42-
A huge thank-you to [@keith-hall][keith] for his work on this.
65+
A huge thank-you is owed
66+
to [@keith-hall][keith]
67+
for his work on this.
4368

4469
### Current Support
4570

4671
#### Highlighting
4772

48-
The highlighting is not exhaustive, nor is it perfect. Expect some problems.
73+
- Support for many `@` expressions
74+
- See Known Issues below for exceptions
4975

5076
#### Functionality
5177

52-
- Hotkey comment/uncomment server-side comments (<kbd>Ctrl</kbd>+<kbd>/</kbd> or <kbd>Cmd</kbd>+<kbd>/</kbd>)
78+
- Hotkey comment/uncomment server-side comments
79+
(<kbd>Ctrl</kbd>+<kbd>/</kbd> or <kbd>Cmd</kbd>+<kbd>/</kbd>)
80+
81+
### Known issues
82+
83+
- Trouble with `@(` in HTML attributes
84+
if the expression contains `"`
85+
- Trouble with `@` expressions in HTML attributes
86+
if they are inside `@` block expressions
87+
- Trouble with `@` expressions in embedded languages
88+
(i.e. in JavaScript)
89+
if they are inside `@` block expressions
90+
- File new issues [on GitHub][gh]
5391

5492

5593
[pkg]: https://packagecontrol.io/packages/HTML%20(C%23)
5694
[st]: https://www.sublimetext.com/
5795
[ss-docs]: https://www.sublimetext.com/docs/syntax.html
96+
[gh]: https://github.com/michaelblyons/SublimeSyntax-HTML-CSharp
5897
[keith]: https://github.com/keith-hall

0 commit comments

Comments
 (0)