What’s New in PhpStorm 2016.3
Experience The Drive to Develop with new major update of PhpStorm in 2016
Experience The Drive to Develop with new major update of PhpStorm in 2016
Now Docker can be added as a remote PHP interpreter in PhpStorm. It’s easier than ever to set up the development environment with Docker and start PHP Scripts, PHPUnit, Behat, PhpSpec tests, PHP CodeSniffer or PHP Mess Detector inside Docker containers.
PhpStorm 2016.3 adds support for PHPSpec. Now when you are working with PHPSpec in PhpStorm, you will have code completion, navigation and proper inspections helping you work with code. We’ve also added PHPSpec run configurations, so you can run your PHPSpec easily with PhpStorm.
Setting up PHPUnit, Behat and PhpSpec for your project becomes incredibly easy. Now these test frameworks will be detected from composer.json, and you will get a popup tooltip suggesting to configure them automatically.
Semantic highlighting, previously introduced in KDevelop and some other IDEs, is now available in PhpStorm. It extends standard syntax highlighting with unique colors for each parameter and local variable. You can turn this feature on at Settings|Editor|Colors and Fonts|Language Defaults|Semantic highlighting.
In PhpStorm 2016.3 you can complete overridden methods and fields without function and var keywords. After invoking completion you will see a method and a field available to override.
Create new test and Create new class have been improved: now they take into account PSR-0/PSR-4 and allow generation of new folders. Also, if you have a folder marked as Test Source Root, it will be picked up automatically in the directory field while creating a new test.
PhpStorm 2016.3 brings a support of class_alias, which is now defined in PhpStorm and works in accordance with PHP documentation.
The Missing Strict Types Declaration inspection checks whether the declare is present in a file. It gives a warning when declare(strict_types=1); is missing as the first line of the file. Then a related intention allows you to fix this across the whole project, which is especially handy while converting a whole project to PHP 7 with enabled strict types.
In PhpStorm 2016.3 we’ve added a pack of new inspections for code style. These inspections highlight those classes/function/methods/variables-constants which don’t follow naming convention in current project.
In PhpStorm 2016.3 the runtime error prevention has been reworked significantly. It became much smarter and in many cases where PhpStorm was previously unable to detect errors, now you will be notified about it by highlighting the code without even running the code.
In PhpStorm 2016.3 it becomes possible to open several projects in one frame by attaching/detaching a project to/from the current one. This means you can work with multiple projects without window-switching and performs cross-project refactorings.
Version Control comes with the following changes:
You can now see type errors reported by Flow, a static type checking system, right in the PhpStorm editor as you work with your code, without having to save files. You can also use code completion results provided by Flow.
TypeScript code analysis and completion are now powered by the TypeScript language service, thanks to which the errors reported in the editor are now consistent with the compiler. PhpStorm also provides additional powerful refactorings and intentions.
Don’t miss any errors in your stylesheets thanks to integration with Stylelint, a CSS linter. In addition to the built-in PhpStorm inspections, you can now see the errors reported by Stylelint right in the editor.
As usual, all features and improvements of WebStorm are available in PhpStorm either out of the box or with free plugins available in the repository. Other noteworthy web-related features include improved React support, support for jspm imports, Convert to arrow function to help you to upgrade your code to ECMAScript 6, and more.
Database tools in PhpStorm have been improved thanks to our colleagues on the JetBrains DataGrip team:
Major improvements were made in type inference:
In PhpStorm 2016.2 we’ve added a new strict type inspection for PHP 7. With this type hinting support, PHP 7 support in PhpStorm gets even better.
Parsing for PHP 7 and PHP 7.1 has been significantly improved. We’ve added support for PHP 7 Uniform Syntax. Moreover, PHP 7.1 is now supported, including support of visibility modifiers for class constants, keys in the list() construct, null return types and nullable arguments, and multiple catch exceptions.
If language level is set to PHP 7 or higher, PhpStorm will generate getters and setters with return type and scalar parameter type hint.
A new dynamic live template was added to make completing the parameters passed into functions, methods, or class constructors easier. Values of class constants are now shown in the completion lists, and static methods are filtered out from the completion lists.
Smart Type code completion filters the suggestion list and includes only those types that are applicable to the current context. You can invoke it by pressing Ctrl+Shift+Space.
In PhpStorm 2016.2 you will find a new option to analyze more than one call level for @throws generation and inspection. Also, you now have one unified setting which controls both generation as well as inspection for @throws tags.
In PhpStorm 2016.2 we have completely reworked inspection of unused imports that now includes support for namespaces, functions and constants, and added other enhancements.
Now if a declaration of a return type in phpDoc isn’t compatible with the actual return type of a method or a function, the IDE will alert you to this. Return type can now be changed with an automatic quick-fix.
PhpStorm 2016.2 brings a new inspection for calling a static method in a dynamic manner (via -> instead of ::). A new quick, Make call static, was added to make this inspection more helpful for you. This feature is switched off by default; to start using it, adjust the setting at Preferences | Editor | Inspections | Static method called as dynamic.
In PhpStorm 2016.2, you can save any project as a template and create a new one based on it. The Tools menu has a new action, Save Project as Template. As soon as it’s saved, the Template is available as a user-defined template in the New Project window.
In PhpStorm 2016.2, we’ve added support for Joomla! Framework. PhpStorm now bundles the Joomla! Plugin providing many Joomla!-specific features, such as Joomla! Code Style, support for JHtml::_($argument) and JText::_($argument), database prefix support, and more. You can easily add Joomla! Support to your existing project or create a new Joomla! Module/Plugin/Extension right from the Welcome screen.
In PhpStorm 2016.2 you can load a Debug Extension for CLI on demand, e.g. when Debugger/Code coverage is required. This dramatically increases execution speed, by a factor of 2 to 3 in specific cases.
PhpStorm 2016.2 brings support for many features of TypeScript 2.0: optional class members, readonly property, never type, this function type, global module export declaration, resolve for type declarations in @types folder, path mappings based module resolution, and more.
Thanks to the integration with Angular CLI, you can now create new Angular 2 projects from the IDE Welcome screen. And with a collection of Angular 2 Live templates, you’ll have the most used code snippets at your fingertips.
Drag an image to add an img tag with width and height attributes anywhere inside the body tag. Similarly, drag a JavaScript or CSS file into the opened HTML file, and PhpStorm will automatically create a script or a link tag inside the head tag for you.
As usual, all features and improvements of WebStorm are available in PhpStorm either out of the box or with free plugins available in the repository. Other noteworthy web-related features include improved React support, support for jspm imports, Convert to arrow function to help you to upgrade your code to ECMAScript 6, and more.
Version Control comes with the following changes:
PhpStorm 2016.2 borrows from the platform great UI improvements, such as:
The editor in PhpStorm now supports fonts with programming ligatures, like Fira Code, Monoid or Hasklig. Make sure you enable that in Preferences | Editor | Colors and Fonts | Font.
Database tools have been improved thanks to our colleagues on the JetBrains DataGrip team: