CodeRush 18.2

改进了对 JavaScript 和 TypeScript 的支持。
11月 9, 2018
新版本

特性

Web Development Support

  • JavaScript & TypeScript Support - Now in JavaScript (and TypeScript) you can:
    • Work with Structural Highlighting.
    • Quickly select and expand/reduce that selection by logical code blocks with Selection Expand/Reduce.
    • Press Ctrl+W to expand selection and Ctrl+Shift+W to reduce it.
    • Easily navigate through references with Tab to Next Reference.
    • Use Smart Cut & Copy.
    • Easily declare classes, functions, variables, code blocks, expressions and more with a pre-release set of CodeRush Templates for JavaScript and TypeScript development.
    • Navigate through your code with Jump to Symbol.
    • Navigate to a symbol declaration using the Jump To window.
    • Simultaneously select and work with Multiple Selections.
  • CSS Support - CSS language support is available in the following features:
    • Show Color
    • Structural Highlighting
    • Structural Navigation
    • Selection Expand/Reduce
  • HTML and Razor Support - Starting with this release, you can use the following features in HTML, C# Razor, Visual Basic Razor and Aspx files:
    • Selection Expand/Reduce
    • Structural Highlighting
    • Smart Duplicate Line
    • Smart Duplicate Selection

Rich Comments

  • Embedded Images Inside Source Code - New feature giving Visual Studio developers the ability to effortlessly embed images, diagrams, formulas, tables, etc., inside source code (C#, F#, JavaScript, TypeScript, Visual Basic, XAML, HTML, CSS, and XML). You can paste any image from the clipboard, or reference a local file in markdown.
  • Markdown Formatting - With Rich Comments you can apply text formatting right inside the code editor in comments. The following Markdown-like syntax is supported: Bold, Italic, Underline and Strikethrough.
  • Important Comments & Question Comments - CodeRush syntax-highlights important comments and question comments in custom colors you can set.
  • Task-Based Comments - CodeRush highlights comments in the custom color you specify for comments starting with the following task-based tokens: TODO, BUG, HACK and UNDONE.
  • Large & Small Comments - CodeRush gives you the ability to use markdown to create large or small comments. Large comments use one, two, or three "+" characters at the start of the comment, and small comments use one, two, or three "-" characters at the start of the comment. If you prefer markdown syntax, you can also use the hashtag character ("#") to specify comment size.

Code Templates

  • Training Window - The Training Window has been ported from CodeRush Classic. This window shows shortcuts for all CodeRush features and template expansions available at the current caret position.
  • Member Sections - CodeRush templates can now place generated members in dedicated target sections for those members. A member section can start with a comment (including a Rich Comment) or be contained inside a region.
  • Selection to Template Improvements - With this release, Selection to Template has become more intelligent - it generates cleaner templates and uses type links, text links, or regular links intelligently depending on the element type. The Create Template has also been enhanced from Selection dialog options, allowing you to fine-tune a template before committing it to your library and quickly specify which elements should be replaced with links.

Refactorings and Code Providers

  • Pull Member Up - With the Pull Member Up refactoring you can move a member with its dependencies to a base class. If there are several base classes, you can select the required class from the sub menu.
  • C#7 Support
    • Conditional to Switch and Switch to Conditional refactorings now support pattern matching.
    • Compress to Ternary Expression and Expand Ternary Expression refactorings now support ref ternary expressions.
  • Miscellaneous Improvements
    • The Declare Method code provider is now available when the caret is located at the end of the line ending with an undeclared method reference.
    • The XPO Fields code provider now copies the [Obsolete] attribute from fields to their corresponding properties.
    • Added a Collapse Accessors code formatter, which collapses both get and set property accessors into single-line form.

Code Cleanup

  • Copyright Header - Added a Copyright Header Code Provider, which can automatically add a copyright comment to the top of the file. It is also available as a Code Cleanup provider and as a template - just press the letter ‘h’ at the top of the file on an empty line and press your template expansion key (e.g. Space or Tab).
  • Cleanup on Save - With the new Apply Code Cleanup when saving a document option, you can automatically clean up your files on save.

Clipboard and Selection Tools

  • Mega Super Copy - You can now use Multi-Select to mark important text elements before selecting and copying/cutting a block of code to get a richer smarter version of the code on the clipboard. Any code in the selection that has been multi-selected will become a Text Fields upon pasting.
  • Member Icons Menu Improvements - Added the Cut, Copy, Select and Comment actions to the Member Icons Menu.
  • Miscellaneous Improvements
    • The Comment/Uncomment Selection feature now supports XAML, XML and CSS languages.
    • The Text Links and Text Fields behavior in Smart Duplicate Line/Selection, Mega Super Copy, and Selection to Template features is now configurable.

Code Analysis

  • You can now set options to determine how the Possible System.NullReferenceException diagnostic performs its analysis in methods, properties, parameters and fields.
  • Added the Task.Factory.StartNew usage can be dangerous code diagnostic, warning when unsafe methods are used to start a new thread.

Code Formatting

  • Code Alignment Improvements - Enhanced formatting options to align code blocks. The "Align content by" and "Indent" options are available on the Braces option page in Editor | C# | Formatting. On the Wrapping option page you can also align content for Initializers.
  • Simple Member Formatting - CodeRush now lets you set formatting options for simple members that include only a single statement (and do not include comments or directives).

Unit Test Runner

  • Enhanced Support for Parameterized Tests - With this release, you can execute a single test case of a parameterized test directly from code. Just click the corresponding CodeRush test icon and choose the desired parameterized test run from the Run test, Debug test, or Run test with coverage submenus.
  • Test Execution Results Export - The test runner now supports exporting test execution results to XML. You can include test name, namespace, state, execution duration (if available), failure details (if the test has failed) and optionally include each test’s XML doc comments in the report.

Miscellaneous Enhancements

  • Performance Improvements
    • You can improve CodeRush performance, making start times even faster, by creating native images using NGEN.exe.
    • If NGEN performance improvements are available, you’ll see a notification near the top of the IDE.
    • You can compile assemblies once for this install, do it automatically after each update, or disregard the suggestion and never see it again.
  • Move to Region Improvements
    • Move to Region now allows you to select target regions from a tree menu (regions are presented in the same hierachical order they appear in code).
    • It can also position methods alphabetically.
  • Jump To Window Improvements
    • The Jump To window is now pre-configurable. You can now define a shortcut that invokes a Jump To window with a pre-configured filter. For example, the shortcut with the "Classes,Methods and Properties,Public" parameters opens the filtered Jump to Symbol window.
Selection Expand/Reduce

CodeRush

可视化代码和直观地进行调试。

有任何疑问吗?

透过Live Chat与我们的DevExpress 专家联络!